Ques 1 If Else
What is the output of the following Python Code?
p=1 q=2 if(p!=q) and (print("Hello")): print("scoder") else: print("hello")
Ques 2 If Else
What is the correct syntax for an if statement in Python?
a) if x > y: print(x)
b) if (x > y) { print(x) }
c) if x > y then print(x)
d) if x > y; print(x)
Ques 3 If Else
Can an if statement in Python be used without an else?
a) Yes
b) No
c) Only with elif
d) None of these