Logo

Python Questions Set 120:

Quiz Mode

  What is returned by math.ceil(3.4)? 

1
2
3
4

Solution:

str = "hope"

l = list(str)

print(l)

1
2
3
4

Solution:

What is the output of the given code?

a=-5

b=4


mod=a%b;


print(mod)

1
2
3
4

Solution:

 Given a string s = “Hello”, which of the following code is incorrect? 

1
2
3

Solution:

Which of the following lines of code will result in an error? 

1
2
3
4

Solution:

Which of the following will print 'Abekus'?

1
2
3
4
5

Solution:

What is the output of the given code?


a=True

b=False


print(a and b)

print(a or b)

1
2
3
4

Solution:

In Flask, the url_for() function is used to build a dynamic URL for a specific function.

1
2
3
4

Solution:

How can we convert Django models into other formats such as XML, JSON, etc.?

1
2
3
4

Solution:

What is the output of the given code?


List=[]

print(List)


List=['Abekus']

print(list)


List=["Abekus","learning","madefun"]

print(List)

1
2
3

Solution: