πŸ“Š JAVA
Q. What are the pillars of OOPS concept?
  • (A) Abstraction, Inheritance, Encapsulation, Polymorphism
  • (B) Atomicity, Inheritance, Encapsulation, Polymorphism
  • (C) Abstraction, Inheritance, Polymorphism
  • (D) None of the Above
πŸ’¬ Discuss
βœ… Correct Answer: (A) Abstraction, Inheritance, Encapsulation, Polymorphism
πŸ“Š JAVA
Q. What is the default buffer size used by any buffered class?
  • (A) 128 bytes
  • (B) 256 bytes
  • (C) 512 bytes
  • (D) 1024 bytes
πŸ’¬ Discuss
βœ… Correct Answer: (C) 512 bytes
πŸ“Š JAVA
Q. Which class cannot be a subclass in java
  • (A) Abstract class
  • (B) Parent class
  • (C) Final class
  • (D) None of above
πŸ’¬ Discuss
βœ… Correct Answer: (C) Final class
πŸ“Š JAVA
Q. Why we use array as a parameter of main method
  • (A) It is syntax
  • (B) Can store multiple values
  • (C) Both of above
  • (D) None of above
πŸ’¬ Discuss
βœ… Correct Answer: (B) Can store multiple values
πŸ“Š JAVA
Q. What is process of defining two or more methods within same class that have same name but different parameters declaration?
  • (A) Method overloading
  • (B) Method overriding
  • (C) Method hiding
  • (D) None of the mentioned
πŸ’¬ Discuss
βœ… Correct Answer: (A) Method overloading
πŸ“Š JAVA
Q. Which of these is correct about passing an argument by call-by-value process?
  • (A) Copy of argument is made into the formal parameter of the subroutine.
  • (B) Reference to original argument is passed to formal parameter of the subroutine.
  • (C) Copy of argument is made into the formal parameter of the subroutine and changes made on parameters of subroutine have effect on original argument.
  • (D) Reference to original argument is passed to formal parameter of the subroutine and changes made on parameters of subroutine have effect on original argument.
πŸ’¬ Discuss
βœ… Correct Answer: (A) Copy of argument is made into the formal parameter of the subroutine.
πŸ“Š JAVA
Q. What is the process of defining a method in terms of itself that is a method that calls itself?
  • (A) Polymorphism
  • (B) Abstraction
  • (C) Encapsulation
  • (D) Recursion
πŸ’¬ Discuss
βœ… Correct Answer: (D) Recursion
πŸ“Š JAVA
Q. Which of the following statements are incorrect?
  • (A) Default constructor is called at the time of declaration of the object if a constructor has not been defined.
  • (B) Constructor can be parameterized.
  • (C) Finalize() method is called when a object goes out of scope and is no longer need
  • (D) None of the above
πŸ’¬ Discuss
βœ… Correct Answer: (C) Finalize() method is called when a object goes out of scope and is no longer need
πŸ“Š JAVA
Q. What is the stored in the object obj in following lines of code? box obj;
  • (A) Memory address of allocated memory of object.
  • (B) NULL
  • (C) Any arbitrary pointer
  • (D) Garbage
πŸ’¬ Discuss
βœ… Correct Answer: (B) NULL
πŸ“Š JAVA
Q. Which of this statement is incorrect?
  • (A) Every class must contain a main() method.
  • (B) Applets do not require a main() method at all.
  • (C) There can be only one main() method in a program.
  • (D) main() method must be made public.
πŸ’¬ Discuss
βœ… Correct Answer: (A) Every class must contain a main() method.