Re:10+ years of experience and no hash maps or Fizz Buzz for...
by lomnakkus on Wednesday June 21, 2017 @06:06AM
(#14602422)
Right, that's why main in Java returns void, and not an Int/Short. Hang on...
Re:10+ years of experience and no hash maps or Fizz Buzz for...
by legulere on Wednesday June 21, 2017 @07:12AM
(#14602692)
Also java main needs arguments, in C `int main(void)` is valid. Java also takes an String[] as a parameter while C takes an int argc and a char argv.
Clearly devnonymous has never programmed in his life if he does not know the exact main function signatures of java and C...
Re:10+ years of experience and no hash maps or Fizz Buzz for...
by devnonymous on Wednesday June 21, 2017 @07:43AM
(#14602817)
When I said...
> should be derivable by anyone who knows how programs work.
That ought to have been a clue. Knowledge of the function signature of the entry point of a program ought to indicate why the signature is the way it is for your favourite programming language. Although now, judging by the replies. Seems like that's a bar a little too high. /sigh, yep I think I should retire soon.
Honestly we can't go from disliking ^typical^ interview questions that have no relation to our daily work all the way to this.
The signature of the main function is standard in possibly every programming language and should be derivable by anyone who knows how programs work.