Unit 1
Unit 2
Miscellaneous
The Class
Pokemon
100

What will be the output of the following code segment?

int x = 15;
int y = 4;
int z = 3;
System.out.println((x + y) / (z - 1));

9

100

Which expression is equivalent to:

!(a && b)

!a || !b

100

The freezing point of water in Celsius

100

This can be seen being eaten by Aliyah every morning

Overnight Oats

100

This pokemon has objectively the worst design of any legendary / mythical

Enamorous

200

What is the final value of x after the following code runs?

int x = 10;
x += 5;
x -= 2;
x *= 3;

39

200

Consider the following code segment:

if (b != 0 && a / b > 100)
{
    statement1;
}
else
{
    statement2;
}

If b has a value of 0 when this segment is executed, what will happen?

An Arithmetic exception will occur

200

video game features blocks falling from the sky

Tetris

200

The total number of classes + Club opportunities that I have the APCSA girls this year

7

200

The number of badges you can win in the Heart gold / soul silver games

16

300

What is a valid single-line comment in Java?

//

300

Consider the following code segment:

for (int i = 1; i <= 4; i++)
{
    for (int j = 1; j <= 4; j++)
    {
        if (i == j)
        {
            System.out.print("* ");
        }
        else
        {
            System.out.print("- ");
        }
    }
    System.out.println();
}

What will be the printed output when run?

* - - -
- * - -
- - * -
- - - *

300

The national fruit of the United States

Blueberry

300

our 3 most frequent guests this year

Kayla, Noa, Lana

300

Rhydon's claim to fame

Being the first pokemon ever created

400

What is the output of the following code?

int x = 10;
int y = 5;
x = x + y;
y = x - y;
System.out.println(y);

10

400

What output will this code segment produce?

for (int i = 5; i >= 1; i--)
{
    for (int j = i; j >= 1; j--)
    {
        System.out.print((4 * j - 1) + " ");
    }
    System.out.println();

19 15 11 7 3
15 11 7 3
11 7 3
7 3
3

400

The number of Bones in the adult human body

206

400

Our Least frequent guest this year


Michal

400

A bonus multiplier added to attacks the same type of the user

S.T.A.B

500

What is wrong with the following code segment:
int x = 3.5;

incorrect variable assignment

500

Given the following code segment:

int sum = 0;
for (int i = 1; i <= 10; i++)
{
    if (i % 2 == 0)
    {
        sum += i;
    }
}
System.out.println(sum);

What will be the output?

30

500

The thing Thomas Hopkins Gallaudet is most famous for

Founding Gallaudet University

500

The total number of class absences

12!

500

The evolution method of the pokemon Inkay

Turning the physical game console upside down as it levels up

M
e
n
u