The document contains questions about Java concepts including: overloading the main method, what a constructor returns, creating a program without a main method, the six ways to use the this keyword, why multiple inheritance is not supported in Java, why use aggregation, overriding static methods, covariant return types, the three uses of the super keyword, using instance initializer blocks, the usage of blank final variables, marker or tagged interfaces, runtime polymorphism or dynamic method dispatch, the difference between static and dynamic binding, how downcasting is possible in Java, the purpose of private constructors, object cloning, why String objects are immutable, how to create an immutable class, the string constant pool, what code is generated for string concatenation using +
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as ODT, PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
35 views1 page
Java Questions
The document contains questions about Java concepts including: overloading the main method, what a constructor returns, creating a program without a main method, the six ways to use the this keyword, why multiple inheritance is not supported in Java, why use aggregation, overriding static methods, covariant return types, the three uses of the super keyword, using instance initializer blocks, the usage of blank final variables, marker or tagged interfaces, runtime polymorphism or dynamic method dispatch, the difference between static and dynamic binding, how downcasting is possible in Java, the purpose of private constructors, object cloning, why String objects are immutable, how to create an immutable class, the string constant pool, what code is generated for string concatenation using +