Python Quiz for Class 7 CBSE Board

Python Quiz for Class 7 CBSE Board

7th Grade

13 Qs

quiz-placeholder

Similar activities

Python programming

Python programming

6th - 12th Grade

16 Qs

Syntax python G7 (Post test)

Syntax python G7 (Post test)

7th Grade

10 Qs

Python Data types & Exceptions

Python Data types & Exceptions

1st - 10th Grade

14 Qs

Python Basics

Python Basics

6th - 7th Grade

15 Qs

Python Syntax

Python Syntax

6th - 12th Grade

14 Qs

Python Variables

Python Variables

7th - 12th Grade

10 Qs

Python Review

Python Review

7th - 8th Grade

17 Qs

Variables - 1

Variables - 1

7th - 8th Grade

9 Qs

Python Quiz for Class 7 CBSE Board

Python Quiz for Class 7 CBSE Board

Assessment

Quiz

Computers

7th Grade

Hard

Created by

Rakesh Kurakula

Used 1+ times

FREE Resource

13 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the main purpose of Python programming language?

To increase the cost of program maintenance

To provide a clear and simple syntax that emphasizes readability and reduces the cost of program maintenance.

To prioritize complex syntax over readability

To make programming more difficult and confusing

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is not a valid data type in Python? A) String B) Float C) Character D) Boolean

B

A

C

D

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of the following code? print(3 + 5 * 2)

10

16

13

7

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is the correct way to start a Python for loop? A) for i in range(5): B) for i = 0; i < 5; i++: C) for i = 1 to 5: D) for i = 1; i < 5; i++

D) for i = 1; i < 5; i++

B) for i = 0; i < 5; i++:

A) for i in range(5):

C) for i = 1 to 5:

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the correct way to define a function in Python? A) define my_function(): B) function my_function(): C) def my_function(): D) func my_function():

C) def my_function():

B) function my_function():

D) func my_function():

A) define my_function():

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

What is the output of the following code? def my_function(x, y): return x + y print(my_function(3, 4))

12

7

34

3

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

Which of the following is the correct way to check if a number is even in Python? A) if num % 2 == 0: B) if num.is_even(): C) if is_even(num): D) if num.even():

A) if num % 2 == 0:

B) if num.is_even():

D) if num.even():

C) if is_even(num):

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?