Consider the following program:
public class Main { public static void main(String []args) { String str = null; if(str instanceof Object) // NULLCHK System.out.println("str is Object"); else System.out.println("str is not Object"); } }
Which one of the following options correctly describes the behavior of this program?
NULLCHK
.NULLCHK
.d)
The variable str was declared but not instantiated; hence the instanceof operator returns false.