No student devices needed. Know more
16 questions
Write your Name , Class and Section
When we type a command, we can see the result immediately in this.
Python Script
Command Line
Python Shell
None of the above
Which of these is NOT a feature of Python?
Open Source
Portable
Used for Game Development
Structured Language
Which punctuation symbols are used to mark the beginning and end of a print command in Python?
{ }
[ ]
( )
< >
Which symbol is a Python Interpreter prompt?
#>
>>>
>
>>
Which of these is a valid comment in Python?
## My Python
# My Python#
# My Python
## My Python ##
Which statement is the correct way to display the message "Welcome to Python"?
display("Welcome to Python")
Print("Welcome to Python")
print("Welcome to Python");
print("Welcome to Python")
When we save a python file, the extension is
.python
.py
.pi
.pt
Special constants with a prefix '\' are called
operators
keywords
constants
escape sequences
In Python the word "Program" is the same as "program"?
Yes
No
The character constant to display output in a newline is
\N
\t
\k
\n
What output will be generated by the following statement?
print("Plan A\\ Plan B")
Plan A, Plan B
Plan A\ Plan B
Plan A\\ Plan B
Plan APlan B
_____________ are storage locations in Python.
constants
Data types
Variables
Operators
Which of these is a correct statement?
A Python program can be run in script mode only
We cannot write multi line programs in the interactive mode
In script mode, we have to save a program to be able to run it
We have to declare comments in a program to be able to run it.
To display the following using a print statement,
Officially, the
first programming language for
a computer
was Plankalkül
the code would be:
print("Officially, the first programming language for a computer was Plankalkül")
print(Officially, the first programming language for a computer was Plankalkül)
print("Officially, the\n first programming language for\n a computer\n was \t Plankalkül")
print(""Officially,\n the first programming \nlanguage for a computer\n was\t Plankalkül")
Which of the following is an incorrect option for the print statement.
Must be enclosed in round parentheses
Can have special characters within double quotes
Cannot be used more than once in a program
May be used to display the result of a mathematical calculation
Explore all questions with a free account