http://www.examulator.com link question
What will happen when you attempt to compile and run the following code?
1) Compile time error, synchronized can only be used in a class that extends
Thread 2) Compile time error, malformed method getFireStation in class Hall.
3) Compilation and output of opposite at runtime
4) Compile time error, code within main method is incorrect.
Answer is 3.Abstract method is implemented in subclass with synchronized on it.what is the use of this manner?This is the first time i have got questions in absract method like this? In what other ways of abstract method implemented in subclass in different ways?Please guide me.