Logo

Java Questions Set 247:

Quiz Mode

Regex class is not a class of java.util.regex 

1
2

Solution:

  Abstract class can be initiated by new operator 

1
2

Solution:

 Which of the following operators can not operate on a boolean variable? 

1
2
3
4

Solution:

Which of the following identifiers is invalid for the main method?

1
2
3
4

Solution:

Which keyword must be used to handle the exception thrown by a try block?

1
2
3
4

Solution:

 If try block executes with no exceptions then finally is called after try block after executing catch block.

1
2

Solution:

class test {

public static void main (String[] args) {

   System.out.println(0.0/0);

}

}

1
2
3
4

Solution:

 public String replaceAll(string replace) replace every subsequence of the input sequence that matches a pattern with a replacement string 

1
2

Solution:

Which Java collection class allows you to grow or shrink its size and provides indexed access to its elements, but whose methods are not synchronized?

1
2
3
4

Solution: