The purpose of this thread is to create a list of possible interview questions in order to get peoples minds oriented around the possible questions that could be asked them during an interview for a position using Java.
I make no discrepency regarding whether the position is server side or client side, requires JNI work, or web-development... the topic is broad, and likely boundless, so if you can think of a (or some) questions, please add them... either ones that you would ask, or ones that you have been asked yourself. Another thing I ask is that if you supply a question, please also supply the answer, or the one that you would like to hear if asking the same question.
Let's start it off simply...
Question: Can static methods access instance variables?
Answer: No... this causes a compile-time error...
-green
I make no discrepency regarding whether the position is server side or client side, requires JNI work, or web-development... the topic is broad, and likely boundless, so if you can think of a (or some) questions, please add them... either ones that you would ask, or ones that you have been asked yourself. Another thing I ask is that if you supply a question, please also supply the answer, or the one that you would like to hear if asking the same question.
Let's start it off simply...
Question: Can static methods access instance variables?
Answer: No... this causes a compile-time error...
non-static variable yourVariable cannot be referenced from a static context
-green