Python test 1

Python test 1

University

20 Qs

quiz-placeholder

Similar activities

Ch.8 - Introducing Python

Ch.8 - Introducing Python

6th Grade - Professional Development

20 Qs

Python introduction

Python introduction

University

15 Qs

Introduction to Python

Introduction to Python

KG - University

25 Qs

PYTHON QUIZ - DAY 2

PYTHON QUIZ - DAY 2

University

15 Qs

For Loops in Python

For Loops in Python

9th Grade - University

20 Qs

For and While Loop in Python

For and While Loop in Python

9th Grade - University

20 Qs

Python1

Python1

University

20 Qs

Python 101

Python 101

University

20 Qs

Python test 1

Python test 1

Assessment

Quiz

Computers

University

Hard

Created by

shahin makubhai

Used 2+ times

FREE Resource

20 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

n Python, a variable may be assigned a value of one type, and then later assigned a value of a different type:

True

False

2.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which one of the following is the correct way of declaring and initializing a variable, x with the value 7?

  1. int x
    x=7

  1. int x=7

  1. x=7

declare x=7

3.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What will be the output of statement 2**2**2**2

  1. 16

256

32768

65536

4.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which of the following statement is False?

  1. Variable names can be arbitrarily long.

They can contain both letters and numbers.

  1. Variable name can begin with underscore.

  1. Variable name can begin with number.

5.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is the output of the following code: print 9//2

  1. 4

4.5

4.0

Error

6.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

Which of the following is not a valid variable name in Python?

  1. _var

  1. var_name

  1. var11

  1. 5var

7.

MULTIPLE CHOICE QUESTION

45 sec • 1 pt

What is the maximum length of an identifier in python?

32

31

63

None of the above

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?