Unit 5 Flashcard  AP CSP

Unit 5 Flashcard AP CSP

Assessment

Flashcard

Computers

9th - 12th Grade

Practice Problem

Hard

Created by

Wayground Content

FREE Resource

Student preview

quiz-placeholder

13 questions

Show all answers

1.

FLASHCARD QUESTION

Front

Correctly write the call to this function.

Media Image

Back

showName()

2.

FLASHCARD QUESTION

Front

There are 55 students in a room. Write a line of code that will determine how many groups of students there will be if there is 4 in each group?

Back

numGroups = 55//4

3.

FLASHCARD QUESTION

Front

Which line of code correctly asks the user for a number of apples that will be multiplied by the price to find the total cost? Options: numApples = int(print("How many apples? ")) , numApples = (input("How many apples?" )) , numApples = int(input("How many apples?" )) , numApples = input(int("How many apples?" ))

Back

numApples = int(input("How many apples?" ))

4.

FLASHCARD QUESTION

Front

What is the process of converting one datatype to another called?

Back

Type Casting.

5.

FLASHCARD QUESTION

Front

What would the program display if you ran this code and entered 2 and then 3 when prompted?

Media Image

Back

The total is 23.

6.

FLASHCARD QUESTION

Front

What would be the answer here?
x = "hello"
print(len(x))

Back

5

7.

FLASHCARD QUESTION

Front

What is the syntax error in this code?

Media Image

Back

The code is not indented correctly

Create a free account and access millions of resources

Create resources

Host any resource

Get auto-graded reports

Google

Continue with Google

Email

Continue with Email

Classlink

Continue with Classlink

Clever

Continue with Clever

or continue with

Microsoft

Microsoft

Apple

Apple

Others

Others

Already have an account?