placeholder image to represent content

VnV AT : M3(Java) - Day 3

Quiz by neelimap

Our brand new solo games combine with your quiz, on the same screen

Correct quiz answers unlock more play!

New Quizalize solo game modes
5 questions
Show answers
  • Q1
    Is it possible in Java to create arrays of length zero ?
    Yes, you can create arrays of any type with length zero.
    No, it is not possible to create arrays of length zero in Java.
    30s
  • Q2
    What is an immutable object?
    an object which cannot be cloned.
    an object which cannot be casted to another type.
    an object whose state cannot be changed after it is created.
    an object whose state can be changed after it is created.
    30s
  • Q3
    What is the base class for all Exception ?
    java.lang.RuntimeException
    java.lang.Exception
    java.lang.Throwable
    java.lang.Error
    30s
  • Q4
    What will be the Output of the given code ? public class test { static void method(){} public static void main(String []args) throws Exception { try { method(); System.out.println("try"); } catch(Exception e) { System.out.println("catch"); } finally { System.out.println("finally"); } } }
    It will not compile
    try catch finally
    try finally
    catch finally
    30s
  • Q5
    What is the output of the following code snippet ? Pattern p = Pattern.compile(".s"); Matcher m = p.matcher("as"); boolean b = m.matches(); System.out.print(b);
    true
    false
    30s

Teachers give this quiz to your class