python-programming-quiz

Python Programming Quiz

A. Python Programming Quiz-1

0%
99

YOUR WELCOME  IN PYHTON PROGRAMMING QUIZ

BEST OF LUCK


Created on
python programming quiz

Python Programming quiz-1

1 / 15

What is the method inside the class in python language?

2 / 15

In which year was the Python language developed?

3 / 15

In which language is Python written?

4 / 15

Which one of the following is the correct extension of the Python file?

5 / 15

Which of the following is not a keyword in Python language?

6 / 15

What do we use to define a block of code in Python language?

7 / 15

In which year was the Python 3.0 version developed?

8 / 15

Which of the following statements is correct for variable names in Python language?

9 / 15

Which character is used in Python to make a single line comment?

10 / 15

Which of the following statements is correct in this python code?

11 / 15

Why does the name of local variables start with an underscore discouraged?

12 / 15

Which of the following statements is correct regarding the object-oriented programming concept in Python?

13 / 15

What is the maximum possible length of an identifier?

14 / 15

Who developed the Python language?

15 / 15

Which of the following declarations is incorrect?

Your score is

The average score is 45%

0%

B. Python Programming Quiz-2

0%
62

YOUR WELCOME  IN PYHTON PROGRAMMING QUIZ

BEST OF LUCK


Created on
Python Programming Quiz

Python Programming Quiz-2

1 / 15

Which of the following precedence order is correct in Python?

2 / 15

What is the output of the following code

print('PYnative ', end='//')print(' is for ', end='//')print(' Python Lovers', end='//')

3 / 15

What is the output of the following code?

sampleList = ["Jon", "Kelly", "Jessa"]sampleList.append(2, "Scott")print(sampleList)

4 / 15

Which of the following operators is the correct option for power(ab)?

5 / 15

What is the output of the following code?

listOne = [20, 40, 60, 80]listTwo = [20, 40, 60, 80]print(listOne == listTwo)print(listOne is listTwo)

6 / 15

In Python3, which functions are used to accept input from the user

7 / 15

What is the output of the following code?

valueOne = 5 ** 2valueTwo = 5 ** 3print(valueOne)print(valueTwo)

8 / 15

What is the output of the following.

set1 = {10, 20, 30, 40, 50}set2 = {60, 70, 10, 30, 40, 80, 20, 50}print(set1.issubset(set2))print(set2.issuperset(set1))

9 / 15

What is the output of the following code.

salary = 8000def printSalary():  salary = 12000  print("Salary:", salary)  printSalary()print("Salary:", salary)

10 / 15

Can we use the “else” clause for loops?

for i in range(1, 5):    print(i)else:    print("this is else block statement" )

11 / 15

Which of the following statements is correct for variable names in Python language?

12 / 15

Which of the following declarations is incorrect in python language?

13 / 15

Which of the following words cannot be a variable in python language?

14 / 15

What is the output of the following set operation

set1 = {"Yellow", "Orange", "Black"}set2 = {"Orange", "Blue", "Pink"}set3 = set2.difference(set1)print(set3)

15 / 15

What is the output of the following code?

p, q, r = 10, 20 ,30print(p, q, r)

Your score is

The average score is 33%

0%

C. Python Programming Quiz-3

0%
40

YOUR WELCOME  IN PYHTON PROGRAMMING QUIZ

BEST OF LUCK


Created on
Python Programming Quiz-3

Python Programming Quiz-3

1 / 15

What is the output of the following print() function

print('%d %d %.2f' % (11, '22', 11.22))

2 / 15

What is a correct syntax to return the first character in a string?

3 / 15

How do you create a variable with the floating number 2.8?

4 / 15

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

5 / 15

How do you create a variable with the numeric value 5?

6 / 15

What is the output of print('[%c]' % 65)

7 / 15

Which of the following is incorrect file handling mode in Python

8 / 15

What will be displayed as an output on the screen

x = float('NaN')print('%f, %e, %F, %E' % (x, x, x, x))

9 / 15

Which one is NOT a legal variable name?

10 / 15

What is the correct syntax to output the type of a variable or object in Python?

11 / 15

Which of the following is incorrect file handling mode in Python

12 / 15

What is a correct syntax to output "Hello World" in Python?

13 / 15

In Python3, Whatever you enter as input, the input() function converts it into a string

14 / 15

What is the output of the following print() function

print(sep='--', 'Ben', 25, 'California')

15 / 15

How do you insert COMMENTS in Python code?

Your score is

The average score is 35%

0%

D.Python Programming Quiz-4

0%
42

YOUR WELCOME  IN PYHTON PROGRAMMING QUIZ

BEST OF LUCK


Created on
Python Programming Quiz-3

Python Programming Quiz-4

1 / 15

Which collection is ordered, changeable, and allows duplicate members?

2 / 15

Which method can be used to replace parts of a string?

3 / 15

What is a correct syntax to output "Hello World" in Python?

4 / 15

How do you start writing a while loop in Python?

5 / 15

What will be displayed as an output on the screen

x = float('NaN')print('%f, %e, %F, %E' % (x, x, x, x))

6 / 15

Which method can be used to return a string in upper case letters?

7 / 15

How do you start writing an if statement in Python?

8 / 15

Which statement is used to stop a loop?

9 / 15

Which collection does not allow duplicate members?

10 / 15

Which of these collections defines a LIST?

11 / 15

Which operator can be used to compare two values?

12 / 15

How do you start writing a for loop in Python?

13 / 15

Which method can be used to remove any whitespace from both the beginning and the end of a string?

14 / 15

Which of these collections defines a TUPLE?

15 / 15

Which operator is used to multiply numbers?

Your score is

The average score is 41%

0%

E. Python Programming Quiz-5

coming soon

 

 

दोस्तों आपको  यह mcqs कैसी लगी कृपया comment करके जरूर बताएं और अगर किसी और subject क mcqs चाहिए तो अपना सुझाव दें/

धन्यवाद |

5 thoughts on “Python Programming Quiz”

Leave a Reply

Your email address will not be published. Required fields are marked *