programming quiz

attempt all question

Question 1 of 20:

What is the output of: if True: print("A") elif False: print("B") else: print("C")?

Question 2 of 20:

What is the output: for a,b in zip([1,2],[3,4]): print(a,b)?

Question 3 of 20:

Which will execute faster for multiple conditions?

Question 4 of 20:

What is the output of: x=5; if x%2==0: print("Even") else: print("Odd")?

Question 5 of 20:

Which operator is used in augmented assignment for bitwise OR?

Question 6 of 20:

Which is correct way to check range in if?

Question 7 of 20:

What will happen if only if is written without else or elif?

Question 8 of 20:

What is the output: [x for x in range(3)]?

Question 9 of 20:

What is the output: x=5; while x: print(x); x-=2?

Question 10 of 20:

Which operator is used to join multiple conditions in if statements?

Question 11 of 20:

What is the output of: x=5; print("Even") if x%2==0 else print("Odd")?

Question 12 of 20:

Which statement executes only when all if conditions are false?

Question 13 of 20:

Which keyword deletes a list completely?

Question 14 of 20:

Which operator is used to concatenate two lists?

Question 15 of 20:

Which function returns the length of a variable in Python?

Question 16 of 20:

What is the output: for i in range(5,1,-1): print(i)?

Question 17 of 20:

Which operator is used in augmented assignment for modulus?

Question 18 of 20:

Which statement exits only inner loop in nested loops?

Question 19 of 20:

Which keyword is used to skip a block of code intentionally?

Question 20 of 20:

What is the output: x=2; if x==1: print("One") elif x==2: print("Two") elif x==3: print("Three") else: print("Other")?