Question-91. What is the GregorianCalender class ?

Answer- The GregorianCalendar provides support for traditional Western calendars.

Question-92. What is an enumeration ?

Answer- An enumeration is an interface containing methods for accessing the underlying data structure from which the enumeration is obtained. It allows sequential access to all the elements stored in the collection.

Question-93. What is the difference between Path and Classpath ?

Answer- Path and Classpath are operating system level environment variales. Path is defines where the system can find the executables(.exe) files and classpath is used to specify the location of .class files.

Question-94. What is constructor chaining and how is it achieved in Java? ?

Answer- A child object constructor always first needs to construct its parent. In Java it is done via an implicit call to the no-args constructor as the first statement.

Question-95. What is the difference between innerclass and nested class ?

Answer- When a class is defined within a scope of another class, then it becomes inner class. If the access modifier of the inner class is static, then it becomes nested class.

Question-96. Why restrictions are placed on method overriding ?

Answer- Overridden methods must have the same name, argument list, and return type. The overriding method may not limit the access of the method it overrides.

Question-97. If a method is declared as protected, where may the method be accessed ?

Answer- A protected method may only be accessed by classes or interfaces of the same package or by subclasses of the class in which it is declared.

Question-98. What are order of precedence and associativity and how they are used ?

Answer- Order of precedence determines the order in which operators are evaluated in expressions. Associativity determines whether an expression is evaluated left-to-right or right-to-left.

Question-99. What is downcasting ?

Answer- It is the casting from a general to a more specific type, i.e. casting down the hierarchy.

Question-100. Define class ?

Answer- A class is a blue print from which individual objects are created. A class can contain fields and methods to describe the behavior of an object.