Advertisement
ftorr91872

Untitled

Feb 16th, 2020
103
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. Assuming that the user enters 60 as the input, what is the output after running the following code snippet?
  2. 1. int num = 0;
  3. 2. cout << "Enter number: ";
  4. 3. cin >> num;
  5. 4. if (num < 10)
  6. 5. {
  7. 6. cout << "Too small!";
  8. 7. }
  9. 8. else if (num < 50)
  10. 9. {
  11. 10. cout << "Intermediate!";
  12. 11. }
  13. 12. else if (num < 100)
  14. 13. {
  15. 14. cout << "High!";
  16. 15. }
  17. 16. else
  18. 17. {
  19. 18. cout << "Too high!";
  20. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement