HCL Interview Questions-Part 3
- Are the imports checked for validity at compile time? e.g. will the code containing an import such as java.lang.ABCD compile?
- Does importing a package imports the subpackages as well? e.g. Does importing com.MyTest.* also import com.MyTest.UnitTests.*?
- What is the difference between declaring a variable and defining a variable?
- What is the default value of an object reference declared as an instance variable?
- Can a top level class be private or protected?
- What type of parameter passing does Java support?
- Primitive data types are passed by reference or pass by value?
Read More »Tags: hcl question, java interview Questions