Let's write a program that will read an age from the keyboard. If the age is in the range from 20 to 60 (inclusive),
then don't display anything. Otherwise, display the phrase "You don't have to work". You can (and must!) do this with only one if statement (without an else block).
Hint: use the || (
To work or not to work? That is the question
- 3
Locked
Comments (4)
- Popular
- New
- Old
You must be signed in to leave a comment
Mihaela
5 October 2023, 18:04
There are no mistakes here.
0
muchemi
2 April 2023, 00:51
Can the support check for mistakes in their tests? This is getting frustrating!
0
John Squirrels Website Admin at CodeGym
3 April 2023, 12:46
What mistakes do you mean? Please provide more details.
0
Anonymous #11229118
25 December 2022, 13:17
They say exclusive but it seems they made a mistake it's from 20 to 60 exclusive ( ]20, 60[ ) otherwise it don't work and in their solution they didn't inlude 20 or 60.
0