Q. What is the output of the following code snippet? int x = 10; int y = 20; cout << (x <= y);

  • (A) 0
  • (B) 1
  • (C) 10
  • (D) 20
πŸ’¬ Discuss
βœ… Correct Answer: (B) 1
Explanation: The less-than-or-equal-to operator (<=) returns true (1) if the first operand is less than or equal to the second.
Explanation by: Shiva Ram
The less-than-or-equal-to operator (<=) returns true (1) if the first operand is less than or equal to the second.

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
128
Total Visits
πŸ“½οΈ
2 y ago
Published
πŸŽ–οΈ
Shiva Ram
Publisher
πŸ“ˆ
97%
Success Rate