Coding

Pyhton Coding Test

0%

Time Limit 10 minutes

Maximum Allowed Time Is over

Your Paper Successfully Sent.


coding

Python

1 / 50

How do you swap two variables in Python?

2 / 50

Which keyword is used to check a condition in Python?

3 / 50

How do you get the remainder of a division?

4 / 50

What is the result of 10 > 5 and 5 < 2?

5 / 50

What is the purpose of the pass statement?

6 / 50

How do you raise a number to a power?

7 / 50

What does str(123) return?

8 / 50

What is the result of "Python" * 2?

9 / 50

How do you check if a string starts with a specific character?

10 / 50

What is the result of 5 * 2 == 10?

11 / 50

What is the result of len("Python")?

12 / 50

What is the output of bool([])?

13 / 50

What is the result of round(2.5)?

14 / 50

How do you open a file in write mode?

15 / 50

How do you declare a variable in Python?

16 / 50

What is the output of [1, 2, 3][1]?

17 / 50

What is the result of bin(10)?

18 / 50

How do you check if a string contains only numbers?

19 / 50

Which module is used for mathematical operations?

20 / 50

How do you round 2.675 to two decimal places?

21 / 50

What does break do in a loop?

22 / 50

What is the result of [1, 2, 3] + [4, 5]?

23 / 50

What is the result of "Python".find("o")?

24 / 50

How do you remove duplicates from a list?

25 / 50

What will range(5) produce?

26 / 50

What is the result of "apple".find("z")?

27 / 50

How do you handle exceptions in Python?

28 / 50

What is the result of 10 // 3?

29 / 50

What does isinstance(x, int) check?

30 / 50

What is the output of len({1, 2, 2, 3})?

31 / 50

How do you create an empty dictionary?

32 / 50

How do you find the index of an element in a list?

33 / 50

What is the output of print(2 + 3)?

34 / 50

What does continue do in a loop?

35 / 50

What is the output of type("123")?

36 / 50

Which function is used to get input from the user?

37 / 50

What is the output of 5 % 2?

38 / 50

What is the keyword used to define a function in Python?

39 / 50

How do you access an element by key in a dictionary?

40 / 50

Which data type is used to store a sequence of characters in Python?

41 / 50

Which method adds an element to the end of a list?

42 / 50

What is the result of 5 >= 5?

43 / 50

How do you get the length of a list?

44 / 50

How do you add an element to a list?

45 / 50

What is the result of bool("")?

46 / 50

What is the result of 3 > 5 or 5 > 2?

47 / 50

What is the output of bool(0)?

48 / 50

What is the output of print(type(10))?

49 / 50

What is the result of 10 != 5?

50 / 50

What is the correct file extension for Python files?