Maximum Digit Finder Quiz

Maximum Digit Finder Quiz

10th Grade

15 Qs

quiz-placeholder

Similar activities

Kuis 1 DPPLG 2

Kuis 1 DPPLG 2

10th - 11th Grade

20 Qs

Flow charts and pseudo code

Flow charts and pseudo code

9th - 11th Grade

16 Qs

GCSE Unit 2 Prep - pseudocode

GCSE Unit 2 Prep - pseudocode

10th Grade

10 Qs

Programming - Selection in an Algorithm

Programming - Selection in an Algorithm

1st - 11th Grade

10 Qs

Algorithm

Algorithm

10th - 11th Grade

15 Qs

Code.org - Unit 6 Review

Code.org - Unit 6 Review

9th - 12th Grade

15 Qs

Kelas X - Algoritma Pemrograman

Kelas X - Algoritma Pemrograman

10th Grade

10 Qs

Info-08 ... Algorithmen

Info-08 ... Algorithmen

8th - 10th Grade

11 Qs

Maximum Digit Finder Quiz

Maximum Digit Finder Quiz

Assessment

Quiz

Computers

10th Grade

Hard

Created by

John Streety

Used 1+ times

FREE Resource

15 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Consider the pseudocode procedure findMaxDigit, which is intended to return the maximum digit in the integer num. For example, if num is 294, findMaxDigit returns 9 because 9 is the maximum digit in 294. What should replace the missing code segment to ensure findMaxDigit works as intended?

num / 10 + 10

num % 10

num * 10

num + 10

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Consider the following function: void drawTriangle () // print a line break after each print statement print "*" print "**" print "***" print "****" end drawTriangle What would happen as a result of calling drawTriangle()?

****

**********

* ** *** ****

* ** *** ****

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Consider the following procedure header: int getSum(int num1, int num2, int num3) Which procedure call is valid?

getSum("A", 96, 95)

getSum(94.5, 96, 95)

getSum(96, 95)

getSum(getSum(92, 93, 95), 96, 95)

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Consider the following pseudocode procedure and procedure call: void practicePassing( pass-by-reference int X, pass-by-value int Y) Y = X / 2 // Division symbol uses integer division X = X + 3 print X, Y end practicePassing Int i = 2 Int j = 3 practicePassing( i, j) print i, j What would print as a result of executing the code?

4 1 4 3

4 1 2 3

6 1 6 3

4 1 2 1

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Consider the following pseudocode procedure: void changeTemp( boolean airFlowing) int currentTemp = 68 if (airFlowing = = true) currentTemp = currentTemp + 2 else print “A/C is off” end if end changeTemp What happens for the method call changeTemp(true)?

“A/C is off” is printed

An error prevents it from executing

The variable currentTemp is increased to 70

“A/C is off” is printed and the variable currentTemp is increased to 70

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Media Image

Which pseudocode procedure is used to draw a circle on a coordinate grid?

drawSquare

drawCircle

drawLine

drawRectangle

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What are the coordinates of the center of the first circle in the correct pseudocode?

(3, 6)

(5, 4)

(7, 2)

(2, 3)

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?