instanceof operator in java | Java Tutorial-40 | latest | 2020

preview_player
Показать описание
Java instanceoff operator is used to identify the type of the object. instanceof operator examine if an object is an instance of the given class or not. instanceof is a comparison operator because it compares an instance with a provided type. It returns either true or false. If any object is compared using instanceof operator with null value then it will always return a false. instanceof handy tool when there are several objects of different classes available and we need to make sure that what is the type of the object.
Рекомендации по теме
visit shbcf.ru