unit 4 assessment

अब Quizwiz के साथ अपने होमवर्क और परीक्षाओं को एस करें!

1. What number will be output by the console.log command on line 7?

100

What number will be output by the console.log command on line 5? oop = 10

16

What will the value of the variable bags be at the end of the flowchart shown here?

2

"You win!" never displays. What line is responsible for this error?

3

what text will be output by the program? score = 0

30 or more

What number will be output by the console.log command on line 5? kit = 20, roo = 10

35

Which of the following is true of functions?

Functions can help remove repeated code from a program

What will be the order of letters printed to the console when this program is run?

a b c b c

Choose the correct definition for Conditional Statement:

affects the sequential flow of control by executing different statements based on the value of a Boolean expression

The customer's age is stored in the variable age and the price is stored in the variable price. Which piece of code will correctly decide the price for each ticket?

age >= 65 price = 6

This function chooses the screen to display based on the score. What is the correct way to call this function?

checkWin

The visitor's age is stored in the variable age, the day of the week is stored in a variable day, and the price in dollars is stored in the variable price. Which piece of code will correctly decide the price for each ticket.

day == tuesday OR day == thursday && age <= 10

When this function is called, the smaller of two numbers is displayed. What Boolean expression would not work in line 12 in order to accomplish this goal?

num1 == num2

What text will be output by the program? age = 15, day = "Sunday"

output D

There is repeated code in these onEvent blocks. Choose the correct code for the updateScreen() function which would be called in each of the onEvent blocks.

setText "counter_label" counter == 0


संबंधित स्टडी सेट्स

Unit 10 : Sales Contracts and Practices

View Set

PM-ks-C12-Procurement-myManyTests

View Set

Real World Chapter 7: Systems of Stratification

View Set

CHAP 41: NURSING CARE OF THE CHILD WITH AN ALTERATION IN PERFUSION/CARDIOVASCULAR DISORDER

View Set

MKT 255 Taelman week 1-6 quizzes EXAM 1 (chapters 1,2,5,7,10,11,12,13)

View Set