Java Level 1 - A

Java Level 1 - A

12th Grade

15 Qs

quiz-placeholder

Similar activities

Java switch/for/while

Java switch/for/while

9th - 12th Grade

15 Qs

Java Recap

Java Recap

12th Grade - University

15 Qs

Loops

Loops

9th - 12th Grade

10 Qs

Java Chapter 1 CS2

Java Chapter 1 CS2

9th - 12th Grade

16 Qs

Programación

Programación

12th Grade

12 Qs

Java Programming Basics

Java Programming Basics

12th Grade

17 Qs

Java Strings and Math Quiz

Java Strings and Math Quiz

12th Grade

15 Qs

CSP Arrays

CSP Arrays

10th - 12th Grade

20 Qs

Java Level 1 - A

Java Level 1 - A

Assessment

Quiz

Computers

12th Grade

Medium

Created by

Tom Dawson

Used 2+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

In Java, every application begins with a ______ and must match the file name?

Comment Line

Public Class

Command

Variable

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

The following script will produce the output ?

public class Main {

public static void main(String[] args) {

System.out.println("Hello World");

}

}

An Error message

No output

Hello World

public class Main

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

To printout the text 'Hello world', which syntax code needs to be added inside the Main class below?

public class Main {

public static void main(String[] args) {

????.????.????("Hello World");

} }

out.println.system

print

println.out.System

System.out.println

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which characters below is used to mark the beginning and end of a block of code in Java?

{ }

[ ]

//

/* */

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which Java characters are used for a single line comment (will not executed)?

/*

#

//

**

6.

MULTIPLE SELECT QUESTION

45 sec • 1 pt

What is the command to print the results from the code below?

2 correct answers

public class Main {

public static void main(String[] args) {

System.out.?????(3 + 3);

}

}

println

PrintLN

output

print

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

To correct this code, you would need to do what?

System.out.println(This sentence will produce an error);

Will work without any additional code

Must wrapped text inside double quotations marks with " "

Must use the // or /*

Replace the println with print

Create a free account and access millions of resources

Create resources
Host any resource
Get auto-graded reports
or continue with
Microsoft
Apple
Others
By signing up, you agree to our Terms of Service & Privacy Policy
Already have an account?