PRF01IF01 - IF

no tags 

Write a program that allows user enter an even number. The program must check and show result.

Example format: ouput input 

Example 1:

Please enter an even number:2
Thank you.

Example 2:

Please enter an even number:1 
1 isn't an even number.

Example 3:

Success #stdin #stdout 0s 4504KB

Please enter an even number:Thank you.

Success #stdin #stdout 0s 4500KB

Please enter an even number:1 isn't an even number.

Success #stdin #stdout 0s 4176KB

Please enter an even number:0 is zero.
Please enter an even number:0
0 is zero.

 

 


hide comments
Mostafa 36a2: 2022-06-06 12:20:58

You should print "Please enter an even number:" without endl.


Added by:khanhvh
Date:2020-10-26
Time limit:1s
Source limit:50000B
Memory limit:1536MB
Cluster: Cube (Intel G860)
Languages:All