Tag: programming languages

Questions Related to programming languages

  1. A method is an implementation of an abstraction

  2. A method is an attribute defining the property of a particular abstraction

  3. A method is an operation defining the behavior for a particular abstraction

  4. A method is a blueprint for making operations


Correct Option: C
  1. They pass messages by modifying each other's fields

  2. They pass messages by calling each other's instance methods

  3. They pass messages by modifying the static variables of each other's classes

  4. They pass messages by calling static methods of each other's classes


Correct Option: B

Which of the following is not a legal identifier?

  1. a2z

  2. 52pickup

  3. _class

  4. total#


Correct Option: B
  1. new and delete are keywords in the Java language

  2. try, catch, and thrown are keywords in the Java language

  3. return, goto, and default are keywords in the Java language

  4. for, while, and next are keywords in the Java language


Correct Option: D
  1. char a = '\u0061';

  2. char 'a' = 'a';

  3. char \u0061 = 'a';

  4. ch\u0061r a = 'a';


Correct Option: B
  1. (false | true)

  2. (null != null)

  3. (4 <= 4)

  4. (true & false)


Correct Option: A,C