Which of the following is a correct way to create a boolean in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
True
Answer option 2
true
Answer option 3
TRUE
English
Which of the following is a correct way to create a string in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
'Hello, World!'
Answer option 2
[Hello, World!]
Answer option 3
{Hello, World!}
Reference Link
English
What is the output of print('Python'.upper())?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
PYTHON
Answer option 2
python
Answer option 3
Python
Reference Link
English
Which of the following is a correct way to create a list in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
[1, 2, 3]
Answer option 2
(1, 2, 3)
Answer option 3
{1, 2, 3}
English
Which of the following is a correct way to create a tuple in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
(1, 2, 3)
Answer option 2
[1, 2, 3]
Answer option 3
{1, 2, 3}
English
Which of the following is a correct way to create a dictionary in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
{'key': 'value'}
Answer option 2
['key', 'value']
Answer option 3
('key', 'value')
English
Which of the following is a correct way to comment in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
# This is a comment
Answer option 2
// This is a comment
Answer option 3
/* This is a comment */
English
Which of the following is a correct way to open a file for reading in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
open('file.txt', 'r')
Answer option 2
open('file.txt', 'read')
Answer option 3
open('file.txt', 'w')
English
What is the output of print(3 * 'abc')?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
abcabcabc
Answer option 2
abc*3
Answer option 3
abcabc
Reference Link
English
Which of the following is used to create an anonymous function in Python?
Anonymous (not verified)
Subject
Correct answer position
1
Answer option 1
lambda
Answer option 2
def
Answer option 3
func
English