Compound Operators in Java

Quiz
•
Computers
•
9th - 12th Grade
•
Medium
Patrick Bryar
Used 2+ times
FREE Resource
12 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is printed when the following code segment is executed?
int j = 10;
int k = 8;
j += 2;
k += j;
System.out.print(j);
System.out.print(" ");
System.out.println(k);
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
int x = 5;
int y = 3;
x *= 2;
y += x;
System.out.print(x);
System.out.print(" ");
System.out.println(y);
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is printed when the following code segment is executed?
int a = 12;
int b = 7;
a -= 3;
b *= a;
System.out.print(a);
System.out.print(" ");
System.out.println(b);
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is printed when the following code segment is executed?
int p = 6;
int q = 4;
p /= 2;
q -= p;
System.out.print(p);
System.out.print(" ");
System.out.println(q);
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is printed when the following code segment is executed?
int m = 9;
int n = 2;
m %= 3;
n += m;
System.out.print(m);
System.out.print(" ");
System.out.println(n);
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is printed when the following code segment is executed?
int r = 15;
int s = 5;
r += 10;
s *= r;
System.out.print(r);
System.out.print(" ");
System.out.println(s);
25 125
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What is printed when the following code segment is executed?
int u = 20;
int v = 3;
u -= 5;
v *= u;
System.out.print(u);
System.out.print(" ");
System.out.println(v);
Create a free account and access millions of resources
Similar Resources on Wayground
10 questions
AP CSA Unit 1 & 2 Review

Quiz
•
9th - 12th Grade
15 questions
Java Math

Quiz
•
9th - 12th Grade
16 questions
Loops Quiz

Quiz
•
9th - 12th Grade
10 questions
Quiz 15 - Array Basics

Quiz
•
11th Grade
7 questions
Pentaksiran T4(menulis kod arahan Java)

Quiz
•
11th Grade
13 questions
APCSA Unit 3 Review

Quiz
•
9th - 12th Grade
10 questions
Study Guide - More Advanced Java

Quiz
•
11th - 12th Grade
16 questions
Loops

Quiz
•
5th - 12th Grade
Popular Resources on Wayground
50 questions
Trivia 7/25

Quiz
•
12th Grade
11 questions
Standard Response Protocol

Quiz
•
6th - 8th Grade
11 questions
Negative Exponents

Quiz
•
7th - 8th Grade
12 questions
Exponent Expressions

Quiz
•
6th Grade
4 questions
Exit Ticket 7/29

Quiz
•
8th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
20 questions
One Step Equations All Operations

Quiz
•
6th - 7th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade
Discover more resources for Computers
50 questions
Trivia 7/25

Quiz
•
12th Grade
20 questions
Subject-Verb Agreement

Quiz
•
9th Grade
18 questions
"A Quilt of a Country"

Quiz
•
9th Grade
6 questions
RL.10.1 Cite Evidence

Quiz
•
10th Grade
10 questions
Characteristics of Life

Quiz
•
9th - 10th Grade
14 questions
Algebra 1 SOL Review #1

Quiz
•
9th Grade