Java Programming - Level 2

20 Questions | Total Attempts: 161

SettingsSettingsSettings
Please wait...
Java Programming - Level 2

Grab your Java programming excellence certificate only on https://javasimplify. Blogspot. Com. Terms and conditions to get your certificate:1. You have to attend all questions to pass this exam2. Need Minimum 60% aggregate to pass this quiz. 3. Must have 50% marks to get your verified certificate of java programming level 2 test4. You will get your certificate immediately from Java simplified once you finished the test with passing criteria.


Questions and Answers
  • 1. 
    What is the range of byte data type in Java?
    • A. 

      -128 to 127

    • B. 

      -32768 to 32767

    • C. 

      -2147483648 to 2147483647

    • D. 

      None of the mentioned

  • 2. 
    Which of these coding types ​are used for data type characters in Java?​
    • A. 

      ASCII

    • B. 

      ISO-LATIN- 1

    • C. 

      UNICODE

    • D. 

      None of the mentioned

  • 3. 
    Literals in java must be appended ​to which of these?​
    • A. 

      L

    • B. 

      I

    • C. 

      D

    • D. 

      L and I

  • 4. 
     What is the prototype of the default constructor of this class?
    • A. 

      Prototype( )

    • B. 

      Prototype(void)

    • C. 

      Public prototype(void)

    • D. 

      Public prototype( )

  • 5. 
    Which of these is an incorrect array declaration?
    • A. 

      Int arr[] = new int[5]

    • B. 

      int [] arr = new int[5]

    • C. 

      Int arr[] = new int[5]

    • D. 

      Int arr[] = int [5] new

  • 6. 
    With x = 0, which of the following are legal lines of Java code for changing the value of x to1?
    1. x++;
    2. x = x + 1;
    3. x += 1;
    4. x =+ 1;
    • A. 

      1, 2, & 3

    • B. 

      1 & 4

    • C. 

      1, 2, 3 & 4

    • D. 

      3 & 2

  • 7. 
    Which operator is used to invert all the digits in​ the binary representation of a number?
    • A. 

      ~

    • B. 

    • C. 

      >>>

    • D. 

      ^

  • 8. 
    Which of these is returned by “greater than”, “less than” and “equal to” operators?
    • A. 

      Iterator

    • B. 

      Floating - point numbers

    • C. 

      Boolean

    • D. 

      None of the mentioned

  • 9. 
    What should be expression1 evaluate to in using​ the ternary operator as in this ​​ expression1 ? expression2 : expression3line?​ 
    • A. 

      Integer

    • B. 

      Floating - point numbers

    • C. 

      Boolean

    • D. 

      None of the mentioned

  • 10. 
    Which keyword is used by​ the method to refer to the object that invoked it?​
    • A. 

      Import

    • B. 

      Catch

    • C. 

      Abstract

    • D. 

      This

  • 11. 
    Which of this keyword is used to make a class?
    • A. 

      Class

    • B. 

      Struct

    • C. 

      Int

    • D. 

      None of the mentioned

  • 12. 
    Which of these can be overloaded?
    • A. 

      Methods

    • B. 

      Constructors

    • C. 

      All of the mentioned

    • D. 

      None of the mentioned

  • 13. 
    Which of these is used to access ​member of class before the object of that class is created?
    • A. 

      Public

    • B. 

      Private

    • C. 

      Static

    • D. 

      Protected

  • 14. 
    Which of these keywords is used to prevent content of a variable from being modified?
    • A. 

      Final

    • B. 

      Last

    • C. 

      Constant

    • D. 

      Static

  • 15. 
    Which of ​this method of String class is used to obtain character at specified index?
    • A. 

      Char()

    • B. 

      Charat()

    • C. 

      Charat()

    • D. 

      CharAt()

  • 16. 
    Which of these operators can be used to concatenate two or more String objects?
    • A. 

      +

    • B. 

      +=

    • C. 

      &

    • D. 

      ||

  • 17. 
    Which of these is a mechanism for naming and visibility control of a class and its content?
    • A. 

      Object

    • B. 

      Packages

    • C. 

      Interfaces

    • D. 

      None of the Mentioned

  • 18. 
    Which of these process occur automatically by java ​runtime system?
    • A. 

      Serialization

    • B. 

      Garbage collection

    • C. 

      File Filtering

    • D. 

      All of the mentioned

  • 19. 
    Which of ​this interface is implemented by Thread class?
    • A. 

      Runnable

    • B. 

      Connections

    • C. 

      Set

    • D. 

      MapConnections

  • 20. 
    What does AWT ​stand for?
    • A. 

      All Window Tools

    • B. 

      All Writing Tools

    • C. 

      Abstract Window Toolkit

    • D. 

      Abstract Writing Toolkit

Back to Top Back to top