Java Printing Quiz

Quiz
•
Computers
•
8th Grade
•
Hard
Elisa Lovejoy
FREE Resource
11 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the proper syntax for the print method for printing in Java?
print()
println()
printf()
display()
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which method is used to print variables and literals in Java?
print()
println()
printf()
display()
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? int x = 5; System.out.print(x);
5
0
null
Error
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? String name = "John"; System.out.println("Hello, " + name);
Hello, John
Hello, name
Hello, null
Error
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is a valid way to print the value of a variable in Java?
System.out.print(variable)
System.out.print("variable")
System.out.print('variable')
System.out.print("'variable'")
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? int a = 10; int b = 20; System.out.println(a + b);
1020
30
Error
null
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is the output of the following code? System.out.print(10 + "20");
1020
30
Error
null
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
Python Programming

Quiz
•
7th - 9th Grade
10 questions
Logic Building in Java Part 1

Quiz
•
6th - 9th Grade
16 questions
Year 9 Python Programming Quiz

Quiz
•
8th Grade
12 questions
S3 Python 1

Quiz
•
8th - 10th Grade
12 questions
Lesson 9 - The internet

Quiz
•
8th Grade
10 questions
Lesson 1 Python I Review

Quiz
•
6th - 8th Grade
10 questions
KS4 Programming Techniques (1)

Quiz
•
8th - 10th Grade
12 questions
Python

Quiz
•
7th - 8th Grade
Popular Resources on Wayground
15 questions
Hersheys' Travels Quiz (AM)

Quiz
•
6th - 8th Grade
20 questions
PBIS-HGMS

Quiz
•
6th - 8th Grade
30 questions
Lufkin Road Middle School Student Handbook & Policies Assessment

Quiz
•
7th Grade
20 questions
Multiplication Facts

Quiz
•
3rd Grade
17 questions
MIXED Factoring Review

Quiz
•
KG - University
10 questions
Laws of Exponents

Quiz
•
9th Grade
10 questions
Characterization

Quiz
•
3rd - 7th Grade
10 questions
Multiply Fractions

Quiz
•
6th Grade