Computer Knowledge

Java Core Classes and Threads

1,935 Questions

Java core classes and threads form the foundation of object oriented programming and are crucial for IT officer and programming exams. This includes concepts like string mutability, collections, and multithreading. Solve these questions to test your practical coding and theoretical knowledge.

String and StringBuffer classesThread execution methodsJava collections frameworkCharacter streams input outputVariable serialization rules

Java Core Classes and Threads Questions

Multiple choice
  1. This event class is used to determine that the particular item is selected or deselected.

  2. This event class is used to determine that the specific action is performed on an item.

  3. This event class is used to determine that the values of the scrolling components are changed by the user.

  4. This event class is used to determine that the particular item loses or gains the focus.

  5. None of the above

Reveal answer Fill a bubble to check yourself
A Correct answer
Explanation

This is true about ItemEvent class.

Multiple choice
  1. This method is used to convert the string values into integers.

  2. This method is used to get the string representation of the number values.

  3. This method is used to get the string values from the char array.

  4. This method is used to split the string.

  5. None of the above

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

This is a true statement.

Multiple choice
  1. It returns the next token as a String.

  2. It returns the next token as an Object.

  3. It returns the number of tokens left to be parsed.

  4. It returns true if one or more tokens remain in the string.

  5. None of the above

Reveal answer Fill a bubble to check yourself
B Correct answer
Explanation

This is task of nextElement() in StringTokenizer class.