Tutorial

Core Java Quiz

Published on August 3, 2022
author

Pankaj

Core Java Quiz

Welcome to Core Java Quiz. Java is an object-oriented programming language.

Core Java Quiz

In this quiz, you will be tested on Core Java basics and OOPS concepts. There are some code snippets too to test your basic Java coding skills.

Some of the questions have multiple answers. You can click on the “Reveal Answer” button for the correct answer and explanation.

Give it a try and share it with others if you like it.

1. Which of the below is valid way to instantiate an array in java?

A. int myArray [] = {1, 3, 5};
B. int myArray [] [] = {1,2,3,4};
C. int [] myArray = (5, 4, 3);
D. int [] myArray = {“1”, “2”, “3”};

Click to Reveal Answer

Correct Answer: A

int [] myArray = {“1”, “2”, “3”}; is invalid because String can’t be converted to an int.

int [] myArray = (5, 4, 3); is invalid because array elements should be defined in curly braces ({}).

int myArray [] [] = {1,2,3,4}; is invalid because myArray is a two-dimensional array whereas in this case it’s being defined as a one-dimensional array. The compiler will complain as Type mismatch: cannot convert from int to int[].

2. Which of the below are reserved keyword in Java?

A. array
B. goto
C. null
D. int

Click to Reveal Answer

**Correct Answer: B, D
**
The goto and int are reserved keywords in java. array and null are not keywords in java.

3. What will happen if we try to compile and run below program?

interface Foo{ int x = 10;}

public class Test { 
    public static void main(String[] args) { 
        Foo.x = 20; 
        System.out.println(Foo.x); 
    }
}

A. Prints 10
B. Prints 20
C. Compile Time Error
D. Runtime error because Foo.x is final.

Click to Reveal Answer

**Correct Answer: C
**
By default, any field of the interface is public, static, and final. So we can’t change is, hence compile-time error at the statement Foo.x = 20;.

4. What will be the output of the below program?

public class Test {
	public static void main(String[] args) {
		char c = 65;
		System.out.println("c = " + c);
	}
}

A. Compile Time Error
B. Prints “c = A”
C. Runtime Error
D. Prints “c = 65”

Click to Reveal Answer

**Correct Answer: B
**
Java compiler tries to automatically convert int to char. Since 65 gets converted to A, hence output will be “c = A”. The char values range is from u0000 to uffff. So char c = 65535; is valid but char c = 65536; will give compile time error.

5. What will be output of below program?

public class Test { 
    public void main(String[] args) {
        int x = 10*20-20; 
        System.out.println(x); 
    }
}

A. Runtime Error
B. Prints 180
C. Prints 0
D. Compile-time error.

Click to Reveal Answer

Correct Answer: A

Runtime error because main method is not static. The error message will be Main method is not static in class Test, please define the main method as: public static void main(String[] args)

6. What are the valid statements for static keyword in Java?

A. We can have static block in a class.
B. The static block in a class is executed every time an object of class is created.
C. We can have static method implementations in interface.
D. We can define static block inside a method.

Click to Reveal Answer

**Correct Answers: A, C
**
We can have static block in a class, it gets executed only once when class loads. From java 8 onwards, we can have static method implementations in interfaces.

7. Select all the core concepts of OOPS.

A. Abstraction
B. Inheritance
C. Interface
D. Polymorphism
E. Generics

Click to Reveal Answer

Correct Answers: A, B, D

OOPS core concepts are;

  1. Abstraction
  2. Encapsulation
  3. Polymorphism
  4. Inheritance
  5. Composition
  6. Association
  7. Aggregation

Read more at OOPS Concepts

8. Which of the following statements are true for inheritance in Java?

A. The “extend” keyword is used to extend a class in java.
B. You can extend multiple classes in java.
C. Private members of the superclass are accessible to the subclass.
D. We can’t extend Final classes in java.

Click to Reveal Answer

**Correct Answer: D
**
Inheritance is one of the core concepts in Java. You should be familiar with it. Please read the following articles to learn more about the answer choices - Inheritance in Java, Multiple Inheritance in Java.

9. What will be the output of below program?

package com.journaldev.java;

public class Test {
	public static void main(String[] args) {
		Super s = new Subclass();
		s.foo();
	}
}

class Super {
	void foo() {
		System.out.println("Super");
	}
}

class Subclass extends Super {
	static void foo() {
		System.out.println("Subclass");
	}
}

A. Compile time error
B. Super
C. Subclass
D. Runtime error

Click to Reveal Answer

**Correct Answer: A
**
Subclass foo() method can’t be static, it will give compile time error This static method cannot hide the instance method from Super.

10. What will be the output of below program?

package com.journaldev.java;

public class Test {
	public static void main(String[] args) {
		Subclass s1 = new Subclass();
		s1.foo(); // line 6
		Super s = new Subclass();
		s.foo(); // line 8
	}
}

class Super {
	private void foo() {
		System.out.println("Super");
	}
}

class Subclass extends Super {
	public void foo() {
		System.out.println("Subclass");
	}
}

A. Compile time error at line 6
B. Compile time error at line 8
C. Compile time error at both line 6 and 8
D. Works fine and prints “Subclass” two times.

Click to Reveal Answer

**Correct Answer: B
**
Compile time error at line 8 because Super class foo() method is private. The error message is The method foo() from the type Super is not visible.

11. What will be the output of below program?

import java.io.IOException;

public class Test {
	public static void main(String[] args) {
		try {
			throw new IOException("Hello");
		} catch (IOException | Exception e) {
			System.out.println(e.getMessage());
		}
	}
}

A. Compile-time error
B. Prints “Hello”
C. Runtime Error

Click to Reveal Answer

Correct Answer: A

Compile-time error as The exception IOException is already caught by the alternative Exception.

12. What will be the output of below program?

public class Test {
	public static void main(String[] args) {
		String x = "abc";
		String y = "abc";
		x.concat(y);
		System.out.print(x);
	}
}

A. abcabc
B. abc
C. null

Click to Reveal Answer

**Correct Answer: B
**
x.concat(y); will create a new string but it’s not assigned to x, so the value of x is not changed.

13. Which of the below are unchecked exceptions in java?

A. RuntimeException
B. ClassCastException
C. NullPointerException
D. IOException

Click to Reveal Answer

**Correct Answer: A, B, C
**
RuntimeException and its subclasses are unchecked exceptions. Unchecked exceptions do not need to be declared in a method or constructor’s throws clause.

14. What will be the output of below program?

package com.journaldev.java;

import java.io.IOException;

public class Test {
	public static void main(String[] args) {
		try {
			throw new Exception("Hello ");
		} catch (Exception e) {
			System.out.print(e.getMessage());
		} catch (IOException e) {
			System.out.print(e.getMessage());
		} finally {
			System.out.println("World");
		}
	}
}

A. Compile-time error
B. Hello
C. Hello World
D. Hello Hello World

Click to Reveal Answer

**Correct Answer: A
**
Compile-time error Unreachable catch block for IOException. It is already handled by the catch block for Exception.

15. Which of the following statement(s) are true for java?

A. JVM is responsible for converting Byte code to the machine-specific code.
B. We only need JRE to run java programs.
C. JDK is required to compile java programs.
D. JRE doesn’t contain JVM

Click to Reveal Answer

Correct Answer: A, B, C

For a complete explanation, read JDK, JRE, and JVM.

16. Can we have two main methods in a java class?

A. Yes
B. No

Click to Reveal Answer

Correct Answer: A

This was a tricky question. We can have multiple methods having name as “main” in java through method overloading.

17. Which of the following statements are true about annotations in java?

A. @interface keyword is used to create custom annotation
B. @Override is a built-in annotation in java
C. Annotations can’t be applied to fields in a class.
D. @Retention is one of the meta annotation in java.
E. Java annotation information gets lost when class is compiled.

Click to Reveal Answer

**Correct Answer: A, B, D
**
For a complete explanation, read Java Annotations.

18. Which of the following statements are true about Enum in java?

A. All java enum implicitly extends java.lang.Enum class.
B. Java enum can implement interfaces.
C. We can create instance of enum using new operator.
D. Enums can’t be used in switch statements.
E. Enum constants are implicitly static and final.

Click to Reveal Answer

**Correct Answer: A, B, E
**
Read more at Enum in Java.

19. Which of the below are built-in class loaders in java?

A. Bootstrap Class Loader
B. Extensions Class Loader
C. Runtime Class Loader
D. System Class Loader

Click to Reveal Answer

Correct Answer: A, B, D

Read more at Classloaders in Java.

20. What will be the output of below program?

package com.journaldev.util;

public class Test {
	public static String toString() {
		System.out.println("Test toString called");
		return "";
	}

	public static void main(String args[]) {
		System.out.println(toString());
	}
}

A. “Test toString called”
B. Compile-time error
C. “Test@7fh2bd8” (Object class toString() method is being called)

Click to Reveal Answer

Correct Answer: B

We will get a compile-time error because we can’t have an Object class method overridden with the static keyword. The Object class has toString() method. You will get a compile-time error as “This static method cannot hide the instance method from Object”.

21. What will be the output of below program?

public class Test {
	public static void main(String[] args) {
		String s1 = "abc";
		String s2 = "abc";
		System.out.println("s1 == s2 is:" + s1 == s2);
	}
}

A. s1 == s2 is:true
B. false
C. s1 == s2 is:false
D. true

Click to Reveal Answer

Correct Answer: B

The given statements output will be “false” because in java + operator precedence is more than == operator. So the given expression will be evaluated to “s1 == s2 is:abc” == “abc” i.e false.

Conclusion

I hope you liked the Core Java Quiz. If you think I have missed some important areas, let me know and I will add some more tricky quiz questions here.

Next Quiz: Java String Quiz

Thanks for learning with the DigitalOcean Community. Check out our offerings for compute, storage, networking, and managed databases.

Learn more about our products

About the author(s)

Category:
Tutorial
Tags:

While we believe that this content benefits our community, we have not yet thoroughly reviewed it. If you have any suggestions for improvements, please let us know by clicking the “report an issue“ button at the bottom of the tutorial.

Still looking for an answer?

Ask a questionSearch for more help

Was this helpful?
 
JournalDev
DigitalOcean Employee
DigitalOcean Employee badge
August 17, 2017

Even if you use a multiple choice approach, the answer may not be true or false. Example given: You asked for java keywords, and rated my answer incorrect. But null is no keyword, nbut the null literal. I noticed several of such things but did’nt took the time to write everything down. I’ll visit again and try to give more comments. Thanks for your efforts, it helps in preparing very simple tasks. But they’re far away from what I excpect fromwhat I expect students at my university to master once they have terminated their bachelor courses.

- Unamuno

JournalDev
DigitalOcean Employee
DigitalOcean Employee badge
August 17, 2017

The question and answers for java keywords are correct, let me drop you an email for this.

- Pankaj

    JournalDev
    DigitalOcean Employee
    DigitalOcean Employee badge
    August 17, 2017

    excelent

    - Williams Ramos Horizonte

      JournalDev
      DigitalOcean Employee
      DigitalOcean Employee badge
      August 17, 2017

      The quiz is very good but IMO it contains mistakes. “null” cannot be used as a name of variable.Therefore, it is a reserved word in Java. This is output from javac. test.java: error: expected String null; ^

      - Yevgeny

      JournalDev
      DigitalOcean Employee
      DigitalOcean Employee badge
      August 17, 2017

      null is not a reserved keyword, please check below link. https://docs.oracle.com/javase/tutorial/java/nutsandbolts/\_keywords.html

      - Pankaj

      JournalDev
      DigitalOcean Employee
      DigitalOcean Employee badge
      August 18, 2017

      true, false, and null might seem like keywords, but they are actually literals; you cannot use them as identifiers in your programs.

      - pa1

        JournalDev
        DigitalOcean Employee
        DigitalOcean Employee badge
        April 17, 2020

        Hi Pankaj, Goto statement is not applicable in JAVA so how goto is keyword for JAVA

        - Rita

          JournalDev
          DigitalOcean Employee
          DigitalOcean Employee badge
          August 17, 2017

          Excellent JAVA Core quiz. I realized that I need to practice more the basic topics, We apreciate all your efforts. Thanks Regards

          - Miguel Torres

            JournalDev
            DigitalOcean Employee
            DigitalOcean Employee badge
            August 17, 2017

            good job…a very good medium for begineers .

            - rahul malgujar

              JournalDev
              DigitalOcean Employee
              DigitalOcean Employee badge
              August 17, 2017

              Good job! Thanks. Only one remark: question " Can we have two main methods in a java class?" The answer no is incorrect. Because yes, we can have 2 methods, for example: public class A { public static void main( Stting [] args) {} public void main( int[] args) {} } Why not?)

              - Aly

              JournalDev
              DigitalOcean Employee
              DigitalOcean Employee badge
              August 17, 2017

              I think you didn’t checked the question properly, you are iterating the same thing in the question explanation.

              - Pankaj

                JournalDev
                DigitalOcean Employee
                DigitalOcean Employee badge
                August 18, 2017

                Description of answer to question 11 about multiple exceptions handling depends on language level, although it’s сompile time error in any case. java multi-catch statement is not supported in -source 1.6

                - Alex

                JournalDev
                DigitalOcean Employee
                DigitalOcean Employee badge
                August 18, 2017

                Hi Alex, Any programming test always assume the latest version. For example, if you have a lambda program, you shouldn’t say that output depends on whether you are on java 8 or lower.

                - Pankaj

                  JournalDev
                  DigitalOcean Employee
                  DigitalOcean Employee badge
                  August 19, 2017

                  Hi I need SQL program like many to one, one to one, one to many on different different kind. who has been asked in interview …

                  - Niranjan Kumaar

                    JournalDev
                    DigitalOcean Employee
                    DigitalOcean Employee badge
                    August 20, 2017

                    doing good job sir

                    - vikash

                      JournalDev
                      DigitalOcean Employee
                      DigitalOcean Employee badge
                      August 22, 2017

                      Greetings from Venezuela, good job

                      - Luis Bravo

                        JournalDev
                        DigitalOcean Employee
                        DigitalOcean Employee badge
                        August 23, 2017

                        Thanks for this great test! It showed me a lot of gaps in my knowledge! It would be great to have some more ! :-)

                        - Svetik

                          JournalDev
                          DigitalOcean Employee
                          DigitalOcean Employee badge
                          September 2, 2017

                          Good questions! Thanks for your quiz.

                          - Peter Alexay

                            JournalDev
                            DigitalOcean Employee
                            DigitalOcean Employee badge
                            September 16, 2017

                            Where to start quiz. I am not able to see any link

                            - Rhushikesh

                            JournalDev
                            DigitalOcean Employee
                            DigitalOcean Employee badge
                            September 16, 2017

                            I was editing the Quiz questions, so it was unavailable for some time. It’s back up again now, please give it a try. Thanks.

                            - Pankaj

                              JournalDev
                              DigitalOcean Employee
                              DigitalOcean Employee badge
                              October 12, 2017

                              Nice to learn via Quiz!

                              - Anita

                                JournalDev
                                DigitalOcean Employee
                                DigitalOcean Employee badge
                                October 15, 2017

                                Good questions. The best part was the explanation of the quiz answers at the end for review.

                                - Sujoy

                                  JournalDev
                                  DigitalOcean Employee
                                  DigitalOcean Employee badge
                                  November 30, 2017

                                  Thanks a lot for the effort put to make this quiz. Really helped refresh all the basics. Now that I have got a taste for a quality quiz, I would love to see similar quiz for more advanced topics like Collections and Threads. Once again, Great work! Thanks.

                                  - Jawad Ali

                                    JournalDev
                                    DigitalOcean Employee
                                    DigitalOcean Employee badge
                                    January 18, 2018

                                    Good questions

                                    - java reader

                                      JournalDev
                                      DigitalOcean Employee
                                      DigitalOcean Employee badge
                                      January 18, 2018

                                      Very instructive

                                      - Yannick loic

                                        JournalDev
                                        DigitalOcean Employee
                                        DigitalOcean Employee badge
                                        February 16, 2018

                                        This was an interesting quiz for me. I just found out I need more practice in Java.

                                        - koreanOppa

                                          JournalDev
                                          DigitalOcean Employee
                                          DigitalOcean Employee badge
                                          March 11, 2018

                                          It was very good quiz!! :) Awesome work

                                          - Raviraj BK

                                            JournalDev
                                            DigitalOcean Employee
                                            DigitalOcean Employee badge
                                            August 23, 2017

                                            Thanks for this great test! It showed me a lot of gaps in my knowledge! It would be great to have some more ! :-)

                                            - Svetik

                                              JournalDev
                                              DigitalOcean Employee
                                              DigitalOcean Employee badge
                                              September 2, 2017

                                              Good questions! Thanks for your quiz.

                                              - Peter Alexay

                                                JournalDev
                                                DigitalOcean Employee
                                                DigitalOcean Employee badge
                                                September 16, 2017

                                                Where to start quiz. I am not able to see any link

                                                - Rhushikesh

                                                JournalDev
                                                DigitalOcean Employee
                                                DigitalOcean Employee badge
                                                September 16, 2017

                                                I was editing the Quiz questions, so it was unavailable for some time. It’s back up again now, please give it a try. Thanks.

                                                - Pankaj

                                                  JournalDev
                                                  DigitalOcean Employee
                                                  DigitalOcean Employee badge
                                                  October 12, 2017

                                                  Nice to learn via Quiz!

                                                  - Anita

                                                    JournalDev
                                                    DigitalOcean Employee
                                                    DigitalOcean Employee badge
                                                    October 15, 2017

                                                    Good questions. The best part was the explanation of the quiz answers at the end for review.

                                                    - Sujoy

                                                      JournalDev
                                                      DigitalOcean Employee
                                                      DigitalOcean Employee badge
                                                      November 30, 2017

                                                      Thanks a lot for the effort put to make this quiz. Really helped refresh all the basics. Now that I have got a taste for a quality quiz, I would love to see similar quiz for more advanced topics like Collections and Threads. Once again, Great work! Thanks.

                                                      - Jawad Ali

                                                        JournalDev
                                                        DigitalOcean Employee
                                                        DigitalOcean Employee badge
                                                        January 18, 2018

                                                        Good questions

                                                        - java reader

                                                          JournalDev
                                                          DigitalOcean Employee
                                                          DigitalOcean Employee badge
                                                          January 18, 2018

                                                          Very instructive

                                                          - Yannick loic

                                                            JournalDev
                                                            DigitalOcean Employee
                                                            DigitalOcean Employee badge
                                                            February 16, 2018

                                                            This was an interesting quiz for me. I just found out I need more practice in Java.

                                                            - koreanOppa

                                                              JournalDev
                                                              DigitalOcean Employee
                                                              DigitalOcean Employee badge
                                                              March 11, 2018

                                                              It was very good quiz!! :) Awesome work

                                                              - Raviraj BK

                                                                JournalDev
                                                                DigitalOcean Employee
                                                                DigitalOcean Employee badge
                                                                March 22, 2018

                                                                This is a good warm up quiz. I realised I still have so many things to do

                                                                - kaka

                                                                  JournalDev
                                                                  DigitalOcean Employee
                                                                  DigitalOcean Employee badge
                                                                  March 26, 2018

                                                                  One of the questions were to select java core concepts from the options. One of the options were ‘Generics’ which was actually a link to Generics page. When I accidentally clicked on it, it took me to another page. Due to this, I could not complete the quiz. Please remove that link so that it won’t happen again for others.

                                                                  - Eswar

                                                                  JournalDev
                                                                  DigitalOcean Employee
                                                                  DigitalOcean Employee badge
                                                                  March 26, 2018

                                                                  Thanks for letting us know, i have fixed it.

                                                                  - Pankaj

                                                                    JournalDev
                                                                    DigitalOcean Employee
                                                                    DigitalOcean Employee badge
                                                                    April 3, 2018

                                                                    Question 6>> WRONG>> My output is Super! I get an error, too, but the question was >> What will be the output of below program?

                                                                    - Hubert

                                                                    JournalDev
                                                                    DigitalOcean Employee
                                                                    DigitalOcean Employee badge
                                                                    April 3, 2018

                                                                    Did you run the code in Eclipse, use command line and you will see that output is correct? Check this thread to understand why you got the output. https://stackoverflow.com/questions/49633887/compiler-error-but-program-executes-fine

                                                                    - Pankaj

                                                                      JournalDev
                                                                      DigitalOcean Employee
                                                                      DigitalOcean Employee badge
                                                                      April 19, 2018

                                                                      Looks like Pankaj sir has made some changes to this set of questions. Earlier I was completely correct, but now the marked answers are showing as the wrong answer but explanation is correct. I also did google and tried output code in eclipse. I am double sure about this mistake. Pankaj sir plz cross check this issue. The explanation shows correct answers and I have marked same answer but it’s highlighted by red color.

                                                                      - Ram Sharan

                                                                        JournalDev
                                                                        DigitalOcean Employee
                                                                        DigitalOcean Employee badge
                                                                        April 17, 2018

                                                                        Are you sure about question 8? I just copied and paste your code on IntelliJ and I got compilation error.

                                                                        - Enrico

                                                                          JournalDev
                                                                          DigitalOcean Employee
                                                                          DigitalOcean Employee badge
                                                                          May 3, 2018

                                                                          Hello Pankaj, Your site has some problem. I have attempted only 5 questions, and finished my quiz.but it showing all the questions are attempted. with incorrect answer.

                                                                          - nisha

                                                                          JournalDev
                                                                          DigitalOcean Employee
                                                                          DigitalOcean Employee badge
                                                                          May 3, 2018

                                                                          Yes, when you finished the quiz. Any question you didn’t attempted will be considered as incorrectly answered. Just like any exams, if you won’t provide answer to a question, you won’t get any marks for it.

                                                                          - Pankaj

                                                                            JournalDev
                                                                            DigitalOcean Employee
                                                                            DigitalOcean Employee badge
                                                                            September 24, 2018

                                                                            Do you have a source code when making this quiz, did you use php for this?

                                                                            - Khyn Harold Jay Antoque

                                                                              JournalDev
                                                                              DigitalOcean Employee
                                                                              DigitalOcean Employee badge
                                                                              October 9, 2018

                                                                              Java Runtime Environment (JRE) contains JVM, class libraries, and other supporting files.

                                                                              - Tom

                                                                                JournalDev
                                                                                DigitalOcean Employee
                                                                                DigitalOcean Employee badge
                                                                                December 12, 2018

                                                                                I’m not sure what java version this was written against, but you most certainly can use Enums in switch statements. You couldn’t use strings in switch statements before Java 7, but even before that you could use Enums. Even the link in the description for why “Enums can’t be used in switch statements.” says that they can be used in switch statements.

                                                                                - Nate

                                                                                JournalDev
                                                                                DigitalOcean Employee
                                                                                DigitalOcean Employee badge
                                                                                December 13, 2018

                                                                                Yes, you are right and so does the question. You have to select statements that are true for Enum.

                                                                                - Pankaj

                                                                                  JournalDev
                                                                                  DigitalOcean Employee
                                                                                  DigitalOcean Employee badge
                                                                                  January 4, 2019

                                                                                  Thanks for the quiz. 15th question blew my mind!

                                                                                  - Naseem Ahamed

                                                                                    JournalDev
                                                                                    DigitalOcean Employee
                                                                                    DigitalOcean Employee badge
                                                                                    September 27, 2019

                                                                                    in question 4 i have copy your code and getting out is ‘c = A’ i have selected that option only but it says wrong option

                                                                                    - Achyut

                                                                                    JournalDev
                                                                                    DigitalOcean Employee
                                                                                    DigitalOcean Employee badge
                                                                                    September 27, 2019

                                                                                    Sorry about that, some error happened when I was editing the question. I have fixed it.

                                                                                    - Pankaj

                                                                                      JournalDev
                                                                                      DigitalOcean Employee
                                                                                      DigitalOcean Employee badge
                                                                                      February 18, 2020

                                                                                      The JRE includes the JVM, which is what actually interprets the byte code and runs your program. To do this the JVM uses libraries and other files provided by the JRE.

                                                                                      - joey

                                                                                        JournalDev
                                                                                        DigitalOcean Employee
                                                                                        DigitalOcean Employee badge
                                                                                        March 25, 2020

                                                                                        LOL , at first question , answer is wrong The correct will be int[] array={1,2,3}; Not int array[] = {1,2,3};

                                                                                        - Dragos Todoroscean

                                                                                        JournalDev
                                                                                        DigitalOcean Employee
                                                                                        DigitalOcean Employee badge
                                                                                        March 26, 2020

                                                                                        Did you ever try to run it? I did and here it is from the Shell.

                                                                                        jshell> int myArray [] = {1, 3, 5};
                                                                                        myArray ==> int[3] { 1, 3, 5 }
                                                                                        
                                                                                        jshell> int[] array={1,2,3};
                                                                                        array ==> int[3] { 1, 2, 3 }
                                                                                        
                                                                                        jshell> int array[] = {1,2,3};
                                                                                        array ==> int[3] { 1, 2, 3 }
                                                                                        

                                                                                        - Pankaj

                                                                                        JournalDev
                                                                                        DigitalOcean Employee
                                                                                        DigitalOcean Employee badge
                                                                                        May 26, 2020

                                                                                        the page shows “There is no question” for me, in all the quizzes! why?

                                                                                        - Azin

                                                                                        JournalDev
                                                                                        DigitalOcean Employee
                                                                                        DigitalOcean Employee badge
                                                                                        May 27, 2020

                                                                                        There was some issue, which has been fixed now.

                                                                                        - Pankaj

                                                                                        JournalDev
                                                                                        DigitalOcean Employee
                                                                                        DigitalOcean Employee badge
                                                                                        May 30, 2020

                                                                                        Thanks, for Question 5, there is no main method in the code, that be static or not

                                                                                        - azin

                                                                                        JournalDev
                                                                                        DigitalOcean Employee
                                                                                        DigitalOcean Employee badge
                                                                                        May 30, 2020

                                                                                        Ah, I mistakenly removed it while doing some editing. I have fixed it.

                                                                                        - Pankaj

                                                                                          JournalDev
                                                                                          DigitalOcean Employee
                                                                                          DigitalOcean Employee badge
                                                                                          May 30, 2020

                                                                                          great work, thanks

                                                                                          - azin

                                                                                            JournalDev
                                                                                            DigitalOcean Employee
                                                                                            DigitalOcean Employee badge
                                                                                            August 5, 2020

                                                                                            Really nice que’s. please update more tricky que’s

                                                                                            - Kokila Viswanathan

                                                                                              JournalDev
                                                                                              DigitalOcean Employee
                                                                                              DigitalOcean Employee badge
                                                                                              March 29, 2021

                                                                                              The last question was the final nail in the coffin. Extremely good questions sir ,Keep making more!!

                                                                                              - Rishabh Sharma

                                                                                                JournalDev
                                                                                                DigitalOcean Employee
                                                                                                DigitalOcean Employee badge
                                                                                                August 8, 2021

                                                                                                Really Good Questions. Thanks sir…

                                                                                                - Himanshu Saxena

                                                                                                  Join the Tech Talk
                                                                                                  Success! Thank you! Please check your email for further details.

                                                                                                  Please complete your information!

                                                                                                  Become a contributor for community

                                                                                                  Get paid to write technical tutorials and select a tech-focused charity to receive a matching donation.

                                                                                                  DigitalOcean Documentation

                                                                                                  Full documentation for every DigitalOcean product.

                                                                                                  Resources for startups and SMBs

                                                                                                  The Wave has everything you need to know about building a business, from raising funding to marketing your product.

                                                                                                  Get our newsletter

                                                                                                  Stay up to date by signing up for DigitalOcean’s Infrastructure as a Newsletter.

                                                                                                  New accounts only. By submitting your email you agree to our Privacy Policy

                                                                                                  The developer cloud

                                                                                                  Scale up as you grow — whether you're running one virtual machine or ten thousand.

                                                                                                  Get started for free

                                                                                                  Sign up and get $200 in credit for your first 60 days with DigitalOcean.*

                                                                                                  *This promotional offer applies to new accounts only.