BETrack-Quiz1-Python

What will be the output of the following code snippet?
 
word="Python Programming"
 
pYtHoN PrOgRaMmInG
python programming
PyThOn pRoGrAmMiNg
PYTHON PROGRAMMING
Which of the following operators are not allowed in strings?
+
-
*
==
2. Find the output of the following program?
nameList=[‘Harsh’, ’Pratik’, ’Bob’, ‘ Dhruv’ ]
print(nameList[-1][-4])
B
p
h
o
Use the below code snippet to find the return value of find_solution(12,15)?
15
12
3
2
What will be the index of ‘o’ in ‘PythonGeeks’?
4 or -7
4 or -6
5 or -7
5 or -6
Which of the following is the correct extension of the Python file?
.python
.pl
.py
.p
Which of the following types of loops are not supported in python?
for
while
do-while
None of the above
What will be the output of the following code snippet?

Example=[“Sunday”,”Monday”,”Tuesday”,”Wednesday”]

Print(Example[-3:-1])

[“Monday”,”Tuesday”]
[“Sunday”,”Monday”]
[“Monday”,”Tuesday”,”Wednesday”]
[“Tuesday”,”Wednesday”,”Sunday”]
What will be the output of the following code snippet?
 
a = [1, 2, 3, 4]
b = [3, 4, 5, 6]
c = [x for x in a if x not in b]
print(c)
[1,2]
[5,6]
[1,2,5,6]
[3,4]
Which of the following is illegal variable name?
myvar
my_var
my-var
_my_var
Which operator is used for single line comments in python?
//
/
#
$
What is the output of the following program?
 
x = 123
for i in x:
    print(i, end=" ")
 
1 2 3
1 1 1
Error
None of the above
0
{"name":"BETrack-Quiz1-Python", "url":"https://www.quiz-maker.com/QQV19S1N0","txt":"What will be the output of the following code snippet?   word=\"Python Programming\", Which of the following operators are not allowed in strings?, 2. Find the output of the following program? nameList=[‘Harsh’, ’Pratik’, ’Bob’, ‘ Dhruv’ ] print(nameList[-1][-4])","img":"https://www.quiz-maker.com/3012/CDN/78-3635484/q8.png?sz=1200-00000011451000005300"}
Powered by: Quiz Maker