Can we use Instanceof in Java?

The instanceof operator in Java is used to check whether an object is an instance of a particular class or not . objectName instanceOf className; Here, if objectName is an instance of className , the operator returns true .

Sizin İçin Seçtik  What method is used to determine the type of an object?

Leave a Reply

Your email address will not be published. Required fields are marked *