Q. Give the output of the following when num1 = 4, num2 = 3, num3 = 2


(a) num1 += num2 + num3

(b) print (num1)

(c) num1 = num1 ** (num2 + num3)

(d) print (num1)

(e) num1 **= num2 + c

(f) num1 = '5' + '5'

(g) print(num1)

(h) print(4.00/(2.0+2.0))

(i) num1 = 2+9*((3*12)-8)/10

(j) print(num1)

(k) num1 = float(10)

(l) print (num1)

(m) num1 = int('3.14')

(n) print (num1)

(o) print(10 != 9 and 20 >= 20)

(p) print(5 % 10 + 10 < 50 and 29 <= 29)


Answer:-


(a) New value assign in variable num1 that is 9 but it will give no output.

(b) It will give output: - 9

(c) New value assign in variable num1 that is 59,049 but it will give no output.

(d) It will give output: - 59,049

(e) It will give an error because here 'c' is not defined.

(f) New value assign in variable num1 that is 55 as a string, but it will give no output.

(g) It will give output: - 55

(h) 1.0

(i) New value assign in variable num1 that is 27.2 but it will give no output.

(j) It will give output: - 27.2

(k) New value assign in variable num1 that is 10.0 but it will give no output.

(l) It will give output: - 10.0

(m) New value assign in variable num1 that is 3.14 but it will give no output.

(n) It will give output: - 3.14

(o) True

(p) True

2 Comments

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Post a Comment

You can help us by Clicking on ads. ^_^
Please do not send spam comment : )

Previous Post Next Post