Search Interview Questions
| More than 3000 questions in repository.|
There are more than 900 unanswered questions.
Click here and help us by providing the answer.
Have a video suggestion.
Click Correct / Improve and please let us know.
|- Interview Questions and Answers for 'Class casting' - 1 question(s) found - Order By Rating|
|Ans. As we only downcast class in the hierarchy, The ClassCastException is thrown to indicate that code has attempted to cast an object to a subclass of which it is not an instance.|
|Help us improve. Please let us know the company, where you were asked this question :|
|Like Discuss Correct / Improve  java   oops   class casting   classcastexception   exception   error Asked in 4 Companies intermediate   frequent|
Try 2 Question(s) Test
|In which cases isn't instanceof operator a bad practice?|
|Invoking start twice on same thread leads to ..|