Conditional statements

Conditional statements

7th Grade

11 Qs

quiz-placeholder

Similar activities

Layouting

Layouting

7th Grade

10 Qs

Latihan Soal Informatika Analisis Data Kelas 7

Latihan Soal Informatika Analisis Data Kelas 7

7th Grade

14 Qs

Guess The Youtuber

Guess The Youtuber

5th - 8th Grade

10 Qs

Python List

Python List

4th Grade - University

15 Qs

Sumatif Harian 3

Sumatif Harian 3

7th Grade

12 Qs

DATA ANALYTICS USING EXCEL

DATA ANALYTICS USING EXCEL

7th Grade

15 Qs

HEALTH AND SAFETY 9

HEALTH AND SAFETY 9

7th - 9th Grade

11 Qs

Encryption and Public Keys

Encryption and Public Keys

6th - 8th Grade

8 Qs

Conditional statements

Conditional statements

Assessment

Quiz

Computers

7th Grade

Hard

Created by

20170418240 PANDEY

Used 112+ times

FREE Resource

AI

Enhance your content in a minute

Add similar questions
Adjust reading levels
Convert to real-world scenario
Translate activity
More...

11 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What signifies the end of a statement block or suite in Python?

}

A comment

End

A line that is indented less than the previous line.

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which one of the following if statements will not execute successfully?

if(1, 2):

print("hello")

if(1, 2):

print("hello")

if(1, 2):

print("hello")

if(1, 2):

print("hello")

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code?


if 'bar' in {'foo':1,'bar':2,'baz':3}:

print(1)

print(2)

if 'a' in 'qux':

print(3)

print(4)

It doesn’t generate any output.

1 2

1 2 3 4

1 2 3

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code?


name = "maria"

if name == "melissa":

print("usa")

elif name == "mary":

print("ireland")

else:

print("colombia")

Usa

Ireland

Colombia

None of the above

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What will be the output of the following code?


if "cat" == "dog":

print("prrrr")

else:

print("ruff")

Prrr

Ruff

Both a and b

None of the above

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

How many choices are possible when using a single if-else statement?

1

2

3

4

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

This operator means that one value is same as the other value

<

==

>

!=

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

By signing up, you agree to our Terms of Service & Privacy Policy

Already have an account?