Search Header Logo

Python Basics

Authored by Bijimol Rajesh

Computers

8th Grade

Used 4+ times

Python Basics
AI

AI Actions

Add similar questions

Adjust reading levels

Convert to real-world scenario

Translate activity

More...

    Content View

    Student View

22 questions

Show all answers

1.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

1.A player wants to remove the space between the variable name and the text when printing. Which of the following is correct?

print('Hello', name + '.')

print('Hello' "name")

print('Hello' name + '.')

print("Hello', name + '.')

2.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

2.A variable name can start with a number.

True

False

3.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

3.The player needs to guess the number. Which of the following code snippets is correct?

pick = input('What is your guess?') 

     num-pick = int(pick)

pick == input('What is your guess?') 

    num_pick = int(pick)

pick = input(“what is your guess’) 

     num_pick = int(pick)

pick = input('What is your guess?') 

    num_pick = int(pick)

4.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

4.What is a string in Python?

A data type used for numbers

A sequence of characters

A Boolean value

A type of loop

5.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

5.Which of the following is the correct syntax to define a variable in Python?

name : 'value'

value => name

name = ('value')

value = "name"

6.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

6.What is the purpose of the else keyword in Python?

To declare a function

To handle code when the if condition is False

To define a loop

To import a module

7.

MULTIPLE CHOICE QUESTION

30 sec • 1 pt

7.Why do you need to use penup() in Turtle graphics?

To refill the pen’s ink

To undo the drawing

To stop the drawing without leaving marks

All of the above

Access all questions and much more by creating a free account

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

Already have an account?