Who invented Java Programming?

Java Quiz

Quiz
•
Other
•
University
•
Hard
Harris onaeshim
FREE Resource
Student preview

10 questions
Show all answers
1.
MULTIPLE SELECT QUESTION
3 mins • 2 pts
Guido van Rossum
Dennis Ritchie
Bjarne Stroustrup
James Gosling
2.
MULTIPLE CHOICE QUESTION
3 mins • 2 pts
Which one of the following is not a Java feature?
Object-oriented
Dynamic and Extensible
Portable
Use of pointers
Answer explanation
Pointers is not a Java feature. Java provides an efficient abstraction layer for developing without using a pointer in Java. Features of Java Programming are Portable, Architectural Neutral, Object-Oriented, Robust, Secure, Dynamic and Extensible, etc.
3.
MULTIPLE CHOICE QUESTION
3 mins • 2 pts
Which of these cannot be used for a variable name in Java?
identifier & keyword
identifier
none of the mentioned
keyword
Answer explanation
Keywords are specially reserved words that can not be used for naming a user-defined variable, for example: class, int, for, etc.
4.
MULTIPLE CHOICE QUESTION
3 mins • 2 pts
What will be the output of the following Java code?
class increment {
public static void main(String args[])
{
int g = 3;
System.out.print(++g * 8);
}
}
32
33
25
24
Answer explanation
Operator ++ has more preference than *, thus g becomes 4 and when multiplied by 8 gives 32.
output:
5.
MULTIPLE CHOICE QUESTION
3 mins • 2 pts
class output {
public static void main(String args[])
{
double a, b,c;
a = 3.0/0;
b = 0/4.0;
c=0/0.0;
System.out.println(a);
System.out.println(b);
System.out.println(c);
NaN
Infinity
0.0
all of the mentioned
Answer explanation
For floating point literals, we have constant value to represent (10/0.0) infinity either positive or negative and also have NaN (not a number for undefined like 0/0.0), but for the integral type, we don’t have any constant that’s why we get an arithmetic exception.
6.
MULTIPLE CHOICE QUESTION
3 mins • 2 pts
Which of the following is a type of polymorphism in Java Programming?
Multiple polymorphism
Compile Time Polymorphism
Mulitilevel Polymorphism
Execution time polymorphism
Answer explanation
There are two types of polymorphism in Java. Compile time polymorphism (overloading) and runtime polymorphism (overriding).
7.
MULTIPLE CHOICE QUESTION
3 mins • 2 pts
What will be the output of the following Java program?
class leftshift_operator
{
public static void main(String args[])
{
byte x = 64;
int i;
byte y;
i = x << 2;
y = (byte) (x << 2);
System.out.print(i + " " + y);
0 256
256 0
0 64
64 0
Answer explanation
Answer: c
Explanation: None.
output:
$ javac leftshift_operator.java $ java leftshift_operator 256 0
Create a free account and access millions of resources
Popular Resources on Quizizz
15 questions
Multiplication Facts

Quiz
•
4th Grade
25 questions
SS Combined Advisory Quiz

Quiz
•
6th - 8th Grade
40 questions
Week 4 Student In Class Practice Set

Quiz
•
9th - 12th Grade
40 questions
SOL: ILE DNA Tech, Gen, Evol 2025

Quiz
•
9th - 12th Grade
20 questions
NC Universities (R2H)

Quiz
•
9th - 12th Grade
15 questions
June Review Quiz

Quiz
•
Professional Development
20 questions
Congruent and Similar Triangles

Quiz
•
8th Grade
25 questions
Triangle Inequalities

Quiz
•
10th - 12th Grade