
APCSA Unit 4 test
Authored by Thomas Wright
Computers
9th Grade
Used 18+ times

AI Actions
Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...
Content View
Student View
35 questions
Show all answers
1.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Write a method that loops until the user inputs the correct secret password or until the user fails to enter the correct password 10 times. The secret password the program should look for is the String "secret"
Assume that a Scanner object called input has been correctly initialized.
2.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What would the method call myMethod("Karel The Dog", 'e') return?
1
2
3
4
3.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What kind of error would the method call myMethod("Frog") cause?
Compile Time Error: String index out of range
Runtime Error: String index out of range
Compile Time Error: Unexpected return value
Runtime Error: Syntax Error in method definition
4.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will the call to the method funWithNumbers(314159) print to the screen?
314159
951413
314
951
5.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What does the call to the method someMethod(3,1) output?
9
12
11
10
6.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
Write a method that will ask for user input until user inputs the String “no”. Allow the user to input any capitalization of the String “no” (“no”, “No”, “NO”, “nO”) Also, have the method return the number of loops.
Assume that a Scanner object input has already been created.
7.
MULTIPLE CHOICE QUESTION
30 sec • 1 pt
What will the call to method patternGrid(3,4,'#') print?
####
####
####
###
###
###
####
####
####
####
This code will error.
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?
Similar Resources on Wayground
31 questions
Simple Machines Quiz 1
Quiz
•
7th - 9th Grade
31 questions
Grade 4- review lesson- exploring email-s2
Quiz
•
3rd - 10th Grade
30 questions
Assessment Quiz
Quiz
•
1st - 12th Grade
38 questions
he
Quiz
•
8th - 10th Grade
30 questions
ข้อสอบปลายภาค รายวิชาวิทยาการคำนวณ
Quiz
•
9th - 12th Grade
30 questions
Exploring MS Access 2010
Quiz
•
9th Grade
30 questions
Programming Techniques
Quiz
•
8th - 10th Grade
30 questions
COMPUTER 3
Quiz
•
3rd Grade - University
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
54 questions
Analyzing Line Graphs & Tables
Quiz
•
4th Grade
22 questions
fractions
Quiz
•
3rd Grade
20 questions
Main Idea and Details
Quiz
•
5th Grade
20 questions
Context Clues
Quiz
•
6th Grade
15 questions
Equivalent Fractions
Quiz
•
4th Grade