Intro Programming: Chapter 2 Review

Intro Programming: Chapter 2 Review

9th - 12th Grade

17 Qs

quiz-placeholder

Similar activities

CO - 1 Quiz - 1-DB_Python Basic

CO - 1 Quiz - 1-DB_Python Basic

10th Grade - University

15 Qs

002_Java Methods

002_Java Methods

12th Grade - University

15 Qs

Java

Java

11th Grade

20 Qs

Java Method

Java Method

12th Grade

19 Qs

Java Arrays Basic

Java Arrays Basic

10th - 12th Grade

15 Qs

5.2 Language Translators Cambridge iAS 9618

5.2 Language Translators Cambridge iAS 9618

11th Grade

15 Qs

STATIC KEYWORD IN JAVA

STATIC KEYWORD IN JAVA

9th - 12th Grade

18 Qs

APCSA  Unit 1 Review

APCSA Unit 1 Review

11th - 12th Grade

20 Qs

Intro Programming: Chapter 2 Review

Intro Programming: Chapter 2 Review

Assessment

Quiz

Computers

9th - 12th Grade

Medium

Created by

Christopher Hayden

Used 123+ times

FREE Resource

17 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is a correct header line for main in a Java program?
public static void main(args)
public static void main(String args)
public static void main(args [ ])
public static void main(String [ ] args)

2.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

What does a comment look like in Java?
//comment
\\comment
==comment
\comment

3.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

public class Sample{
public void Example{
//rest of code
} }
What is the name of the file?
Sample.java
sample.java
example.java
Example.java

4.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

Assume the following code works as intended:
int a = 12;
a = a + 3;
Suppose we want to display the current value of a; what will that line of code be?
System.out.print(a);
System.out.print(12);
System.out.print("12");
System.out.print("a");

5.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

One of these words should be uppercase, but is currently lowercase; which word needs to be capitalized?
public class First{  
public static void main(String[ ] args)  {  system.out.printLn("this is a test!");  }}
public
main
this
system

6.

MULTIPLE CHOICE QUESTION

1 min • 1 pt

public class Monday{  
< The header line for main >  
{   System.out.println("Greetings");  }}
What can be the name of the source file for this program?
Monday.java
monday.java
Monday.java or monday.java
any name with the extension .java

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Java is an example of a _________ programming language.
compiled
interpreted
compiled/interpreted
low level

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?