Suppose list1=[1,2,3] ,then list*2 is
What is the output of the following code?
import math
a = 10.3
b = math.ceil(a)
print(b)
What is the output of the following code?
>>> a = 83.
>>> b = 6
>>> a // b
>>> x = 2
>>> y = x * 2
>>> x = 3
>>> x = y + 1
>>> z = 2 ** y
>>> z
What is the value of 'z'?
What will be the output of the following Python code?
>>> a={1:"A",2:"B",3:"C"}
>>> a.items()
Fill in the blank in the following Python code to calculate the factorial of a number.
def fact(num):
if num == 0:
return 1
else:
return num*fact(num-1)
import re
text="avrhj@rjgn.irg to jngrj@ioer.njvk"
pattern=re.compile("[a-zA-Z0-9]+@[a-zA-Z0-9]+\.[a-zA-Z]+")
result=pattern.findall(text)
print(type(result))
What does the above code prints?
What is the purpose of the 'send_message()' method in the Mail class?