What is the purpose of the "instanceof" operator in Java?
A. To check if an object is an instance of a specific class or interface.
B. To convert a primitive type to its corresponding wrapper class.
C. To concatenate two strings.
D. None of the above.
Answer:A
What is the purpose of the "instanceof" operator in Java?
A. To check if an object is an instance of a specific class or interface. B. To convert a primitive type to its corresponding wrapper class. C. To concatenate two strings. D. None of the above.