Python Iteration
a year ago
mrcwoodhead
Save
Edit
Host a game
Live GameLive
Homework
Solo Practice
Practice
13 QuestionsShow answers
  • Question 1
    20 seconds
    Q.

    What is a Count-Controlled loop?

    answer choices

    for loop

    while loop

  • Question 2
    20 seconds
    Q.

    A count controlled loop will..

    answer choices

    Repeat code until a condition is met

    Repeat code a specific amount of times

    Repeat code a random amount of times

    None of the above

  • Question 3
    20 seconds
    Q.

    What will this code do?

    answer choices

    Print Numbers 1-11

    Print Numbers 1-10

    Print Numbers 2-10

    Print Error

  • Question 4
    20 seconds
    Q.

    What sort of loop is this?

    answer choices

    Count Controlled

    Condition Controlled

  • Question 5
    30 seconds
    Q.

    What will this code print?

    answer choices

    Print the word 'letter'.

    Print a user input on one line.

    Print a user input one letter at a time.

    Print an Error.

  • Question 6
    20 seconds
    Q.

    Which of these is NOT a loop in python?

    answer choices

    for loop

    while loop

    nested loop

    if loop

  • Question 7
    20 seconds
    Q.

    Which of these operators means EQUAL TO?

    answer choices

    '='

    '=>'

    '<='

    '=='

  • Question 8
    20 seconds
    Q.

    What will be the output of this code?

    answer choices

    1,2,3,4,5,6,7,8,9,10,11,12

    0,2,4,6,8,10

    2,4,6,8,10,12

    2,4,6,8,10

  • Question 9
    20 seconds
    Q.

    What does the '#' allow you to do?

    answer choices

    Repeat code

    Comment on code

    Print code

    End code

  • Question 10
    30 seconds
    Q.

    Which of these will allow me to count from 0-20 in steps of 5?

    answer choices

    for x in range(0,20):

    print(x)

    while x = (0,20,5):

    print(x)

    for x in range(0,21,5):

    print(x)

    for x in range(0,21,5):

    print(y)

  • Question 11
    20 seconds
    Q.

    If i want to continuously check for a correct answer, what loop would i use?

    answer choices

    for loop

    while loop

  • Question 12
    30 seconds
    Q.

    What is the error in this code?

    answer choices

    incorrect variable name

    incorrect indentation

    incorrect speech marks

    incorrect loop

  • Question 13
    20 seconds
    Q.

    A condition controlled loop is...

    answer choices

    A while loop

    A for loop

Report Quiz
Join a game