What does System.out.println() do?
Java Basics Quiz for CH/PT Students

Quiz
•
Information Technology (IT)
•
University
•
Medium
Geshani ITUM
Used 23+ times
FREE Resource
16 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
20 sec • 5 pts
Takes user input
Outputs text to the console
Ends a program
None of the above
2.
MULTIPLE CHOICE QUESTION
20 sec • 5 pts
Which keyword is used to define a class in Java?
class
define
struct
object
3.
MULTIPLE CHOICE QUESTION
20 sec • 5 pts
What is the purpose of the public keyword in Java?
It hides the method or class from other classes.
It allows the method or class to be accessed from outside.
It specifies that the method is private.
None of the above.
4.
MULTIPLE CHOICE QUESTION
20 sec • 5 pts
Which of the following is a correct way to declare a variable in Java?
int 1x = 10;
int x = 10;
integer x = 10;
num x = 10;
5.
MULTIPLE CHOICE QUESTION
20 sec • 5 pts
Which data type is used to store a single character in Java?
char
String
int
boolean
6.
MULTIPLE CHOICE QUESTION
20 sec • 5 pts
What will be the value of the variable z after executing the code below? int x = 5, y = 10; int z = x + y;
5
10
15
50
7.
MULTIPLE CHOICE QUESTION
20 sec • 5 pts
What will be the result of the following code? int a = 10, b = 3; System.out.println(a % b);
1
3
10
0
Create a free account and access millions of resources
Similar Resources on Quizizz
15 questions
Java_MCQ_3

Quiz
•
University
17 questions
MCQs on Iterative Statements in Java

Quiz
•
University
17 questions
Codean - Java Loop

Quiz
•
University
12 questions
Aula07 - Matrizes

Quiz
•
University
20 questions
2F-3 | Python Quiz | 14/11/2024

Quiz
•
University
20 questions
Java MCQs on Syntax and Semantics

Quiz
•
University
14 questions
Quiz-Java

Quiz
•
University
11 questions
TRẢ LỜI ĐÚNG - TRÚNG QUÀ COOL

Quiz
•
University
Popular Resources on Quizizz
15 questions
Multiplication Facts

Quiz
•
4th Grade
20 questions
Math Review - Grade 6

Quiz
•
6th Grade
20 questions
math review

Quiz
•
4th Grade
5 questions
capitalization in sentences

Quiz
•
5th - 8th Grade
10 questions
Juneteenth History and Significance

Interactive video
•
5th - 8th Grade
15 questions
Adding and Subtracting Fractions

Quiz
•
5th Grade
10 questions
R2H Day One Internship Expectation Review Guidelines

Quiz
•
Professional Development
12 questions
Dividing Fractions

Quiz
•
6th Grade