Java Beans
More JAVA
Java Talk
Java Control Flow
Java Trivia
100
This method is required in all Java programs: public static void ______ (String[] args) { ... }
What is main?
100

Using the Random class, this method is used to generate a random whole number

What is Random.nextInt()?

100
'c' is an example of this primitive data type
What is char?
100

This Java keyword is used to define a decision-making structure, where different code blocks are executed based on a specific condition

What is "if/switch"?

100

What code editor are we using?

What is IntelliJ?

200

The output of: 

if (5 * 7 < 4 * 9) return true; else return false;

What is true?

200

What is it called when you combine two strings together and what operator do you use?

What is concatenation and the "+" operator?

200
This single symbol is known as the statement terminator

What is a "semicolon"?

200

____ is a keyword that comes after an if statement when the first if statement is not ran.

What is else if / else?
200

What version of Java are we using?

Java 16

300

this prints out something to the console

What is System.out.println() or System.out.print()?

300

Explain what the modulus operator does?

It returns the remainder of a division of two numbers.

300

The Java syntax for creating a single line comment

What is "two forward slashes"? (//)

300

This Java keyword is used to skip the rest of the code inside of a loop and immediately proceed with the next iteration

What is "continue"?

300

What does the void keyword mean?

Void means nothing and is commonly used in functions to indicate that the function should not return anything.

400
the length of the string of “computer science is cool”
What is 24?
400

If you name your Scanner scanner, this piece of code will read a double entered by a user

What is "scanner.nextDouble()?

400
What is b in the following code? int[] b = new int[10];
What is an integer array of size 10?
400

This Java keyword is used to immediately terminate the execution of a loop, executing the next section of code after the loop

What is "break"?

400

What is the difference between naming classes and naming variables or functions?

Classes should start with an uppercase letter (Upper camel case), whereas variables should start with a lowercase letter (lower camel case). Each word after the first word in the variable or class name should be capitalized.

500

The names of 3 primitive data types for numbers in Java

What is short/int/long/float/double?

500

How do you create a for loop that starts at 10 and goes down to (and includes) 0?

for (int i = 10; i >= 0; i--) { ... }

500

This is the process of converting a variable from one data type to another

What is "casting"/"type-casting"?

500

What must you add to specify to Java that a block of code belongs to a part of a conditional statement, loop, function, class, etc.? 

AND, do indentations matter in Java??

You need to write brackets to organize and group your code. Indentations do not matter syntactically but good indentations make your code easier to read.

500

When was Java invented? +/- 3 years

What is 1995?

M
e
n
u