XI-A1 FLOW OF CONTROL G6

XI-A1 FLOW OF CONTROL G6

11th Grade

21 Qs

quiz-placeholder

Similar activities

Quiz Microsoft Word

Quiz Microsoft Word

10th Grade - University

20 Qs

Питон П411

Питон П411

9th - 12th Grade

20 Qs

Python Savollari 2

Python Savollari 2

11th Grade

21 Qs

Quiz de Introdução à Programação

Quiz de Introdução à Programação

11th Grade

17 Qs

Understanding the concept of list

Understanding the concept of list

11th Grade

25 Qs

Python Library Routines Quiz

Python Library Routines Quiz

10th Grade - University

18 Qs

for_students

for_students

11th Grade

20 Qs

Sensor dan Servo Motor Arduino

Sensor dan Servo Motor Arduino

11th Grade

20 Qs

XI-A1 FLOW OF CONTROL G6

XI-A1 FLOW OF CONTROL G6

Assessment

Quiz

Information Technology (IT)

11th Grade

Hard

Created by

Pulkit 1292

FREE Resource

21 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

  1. 1. What is the purpose of an elif clause in Python?

The elif clause is a synonym for the else clause.
The elif clause is used to terminate a loop.

To comment code

To make an alternate branch if the if condition is false

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

  1. 2. L = "45" → datatype of L?

boolean
string
float
integer

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which function converts a string "123" into integer?

int('123')
list('123')
float('123')
str(123)

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

  1. 4. x = 5

if x > 10:

print("A")

elif x > 3:

print("B")

else:

print("C")

B
A
C
D

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

  1. 5. What’s the difference between elif and else?

'elif' is used for loops, while 'else' is not.
The difference is that 'elif' checks an additional condition, while 'else' executes when no previous conditions are true.
'elif' can only be used once, but 'else' can be used multiple times.
'elif' is a synonym for 'else' and has no functional difference.

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

  1. 6. Which of these keywords marks a null operation?

PASS

CONTINUE

BREAK

ELSE

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

  1. 7. x = float(input())

    if (x == 1):

    print("Yes")

    elif (x >= 2):

    print("Maybe")

    else:

    print("No")

    IF USER INPUT 1.5 THEN WHAT WILL BE OUTPUT

YES

NO

MAYBE

NOTHING PRINTED

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?