Java Basics MP1 Test 3

Java Basics MP1 Test 3

Assessment

Flashcard

Computers

11th Grade

Practice Problem

Hard

Created by

Wayground Content

FREE Resource

Student preview

quiz-placeholder

18 questions

Show all answers

1.

FLASHCARD QUESTION

Front

A variable that holds a decimal number

Back

double

2.

FLASHCARD QUESTION

Front

It is a data type used to hold multiple characters, like words and sentences.

Back

String

3.

FLASHCARD QUESTION

Front

What output will be produced by:
System.out.println("Hello");
System.out.print("Karel");

Back

Hello
Karel

4.

FLASHCARD QUESTION

Front

What does the code segment output?

Media Image

Back

Media Image

5.

FLASHCARD QUESTION

Front

What is the value of x after this code runs?
int x = 5;
x = 10;
x = 4;

Back

4

6.

FLASHCARD QUESTION

Front

What will the following code print?
int n = 5;
n++;
n++;
n += n;
System.out.println(n);

Media Image

Back

14

7.

FLASHCARD QUESTION

Front

Refer to the following code segment: The student wanted the output to be: 1 / 4 = 0.25. Which change to the first line would get the correct answer? Options: int myDouble = 1/4;, double myDouble = (double) 1/4;, double myDouble = (int) 1/4;, double myDouble = (int) (1.0/4.0);

Media Image

Back

double myDouble = (double) 1/4;

Access all questions and much more by creating a free account

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?