
11AE-CSC60-SBQ-practice2
Authored by Computer Teacher
Other
11th Grade
Used 3+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
20 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following statements is true about the if statement?
The if statement can have only one condition that evaluates to an integer value.
The if block is optional.
The else block is optional.
The if and else blocks should always be included within curly braces.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following is the correct syntax for an if statement?
if (x < 10) { size = "Small"; } else (x < 20) { size = "Medium"; }
if (x < 10); { size = "Small"; } else (x < 20) { size = "Medium"; }
if (x < 10)
{ size = "Small";
}
else
{
size = "Medium";
}
if { size = "Small"; } else (x < 20) { size = "Medium"; }
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Assuming that the user provides 99 as input, what is the output of the following code snippet? int a; int b; a = 0; Scanner in = new Scanner(System.in); System.out.print("Please enter a number: "); b = in.nextInt(); if (b > 300) { a = b; } else { a = 0; } System.out.println("a: " + a);
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The following code snippet contains an error. What is the error? if (cost > 100); { cost = cost – 10; } System.out.println("Discount cost: " + cost);
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What kind of operator is the <= operator?
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Which of the following operators is used as a relational operator?
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
The operator !> stands for
Access all questions and much more by creating a free account
Create resources
Host any resource
Get auto-graded reports

Continue with Google

Continue with Email

Continue with Classlink

Continue with Clever
or continue with

Microsoft
%20(1).png)
Apple
Others
Already have an account?
Popular Resources on Wayground
15 questions
Fractions on a Number Line
Quiz
•
3rd Grade
20 questions
Equivalent Fractions
Quiz
•
3rd Grade
25 questions
Multiplication Facts
Quiz
•
5th Grade
29 questions
Alg. 1 Section 5.1 Coordinate Plane
Quiz
•
9th Grade
22 questions
fractions
Quiz
•
3rd Grade
11 questions
FOREST Effective communication
Lesson
•
KG
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
Discover more resources for Other
20 questions
-AR -ER -IR present tense
Quiz
•
10th - 12th Grade
22 questions
El Imperfecto
Quiz
•
9th - 12th Grade
15 questions
ACT Reading Practice
Quiz
•
11th Grade
20 questions
SSS/SAS
Quiz
•
9th - 12th Grade
20 questions
verbos reflexivos en español
Quiz
•
9th - 12th Grade
14 questions
Making Inferences From Samples
Quiz
•
7th - 12th Grade
23 questions
CCG - CH8 Polygon angles and area Review
Quiz
•
9th - 12th Grade
8 questions
Momentum and Collisions
Lesson
•
9th - 12th Grade