
Java Programming Quiz
Quiz
•
Computers
•
University
•
Practice Problem
•
Hard
sumathi A
FREE Resource
Enhance your content in a minute
10 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the correct syntax for the main method in Java?
public static void main(String args[])
public void main(String args[])
public static void main(String[] args)
public void main(String[] args)
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is not a Java primitive data type?
int
float
String
char
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the size of an int data type in Java?
4 bytes
2 bytes
8 bytes
1 byte
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is used to create an object in Java?
class
new
import
package
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code snippet? int x = 5; int y = 10; System.out.println(x + y);
510
15
x + y
5 + 10
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which keyword is used to inherit a class in Java?
extends
implements
inherits
super
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the purpose of the final keyword in Java?
To define a constant
To prevent method overriding
To prevent inheritance
All of the above
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Similar Resources on Wayground
10 questions
Què has après sobre el web ?
Quiz
•
University
12 questions
Printf, scanf
Quiz
•
University
10 questions
TIU Quiz-9
Quiz
•
University
12 questions
Javascript
Quiz
•
University
10 questions
Основы Интернета и Веба
Quiz
•
University
10 questions
Programación II Parte 5
Quiz
•
University
15 questions
python basics
Quiz
•
11th Grade - University
15 questions
Шаблоны проектирования
Quiz
•
University
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade
20 questions
Figurative Language Review
Quiz
•
6th Grade
