Python Variables

10 questions Beginner
Question 1 1 point

What is the correct way to create a variable in Python?

Question 2 1 point

Which of the following is a valid Python variable name?

Question 3 1 point

my_name

Question 4 1 point

What will be printed by the following code?

name = "Alice"
print(name)

 

Question 5 1 point

What is the data type of the following variable?

age = 18

 

Question 6 1 point

Which option correctly creates a variable with a decimal number?

Question 7 1 point

What will be the value of x after running the following code?

x = 10
x = 20

 

Question 8 1 point

Which variable contains a Boolean value?

Question 9 1 point

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

Question 10 1 point

What will be the output of the following code?

a = 5
b = 3
print(a, b)