NEW
Font size
WorksheetsPython Basics
Total questions: 23
Worksheet time: 11mins
To display something on the screen, use this command:
print()
Print()
screen()
write()
display()
To display the following on screen
Hello World!
the following command should be used:
print(Hello World!)
print("Hello World!")
print("Hello World" + !)
print"(Hello World!)"
name = 'Dave'
print (name)
Which operator performs a division?
-
+
/
*
Which operator checks if a value is equal to another value?
+
=
==
!=
Which operator checks if a value is not equal to another value?
==
+=
!=
=
Which of the following is correct?
Comments are for programmers for better understanding of the program.
Python Interpreter ignores comment.
You can write multi-line comments in Python using triple quotes, either ''' or """.
All of the above
In the following code, n is a/an _______?
n = '5'
integer
string
tuple
operator
What is used to take input from the user in Python?
cin
scanf()
input()
<>
