UGC NET COMPUTER SCIENCE SOLVED PAPERS 2014-16 - UGC NET Computer Science Paper 3 July 2016

37. Implicit return type of a class constructor is:

  • Option : B
  • Explanation :
    Implicit return type of a class constructor is class type itself. Option (B) is correct.
Cancel reply
Cancel reply

38. It is possible to define a class within a class termed as nested class. There are _____ types of nested classes.

  • Option : A
  • Explanation :
    It is possible to define a class within a class termed as nested class. There are two types of nested classes. 1 - Outer class will use argument of inner class. 2 - Inner and outer class are independent to each other.(different argument) So, optioin (A) is correct.
Cancel reply
Cancel reply

40. Which of the following statements is correct?
(1) Every class containing abstract method must not be declared abstract.
(2) Abstract class cannot be directly initiated with ‘new’ operator.
(3) Abstract class cannot be initiated.
(4) Abstract class contains definition of implementation.

  • Option : C
  • Explanation :
  • Every class containing abstract method must be declared abstract.
  • Abstract class doesn't contains definition of implementation
  • Abstract class cannot be directly initiated with ‘new’ operator and it cannot be initiated. Statement (2) and (3) are correct.
  • So, option (C) is correct.
Cancel reply
Cancel reply