1
0
Fork 0
mirror of https://codeberg.org/DansLeRuSH/c-plus-plus-exercises.git synced 2024-12-21 21:39:05 +00:00

Even or odd number ?

This commit is contained in:
Franck ALBARET 2018-10-22 07:02:32 +00:00
parent 6e3fc41ca1
commit 56e36351c6

View file

@ -0,0 +1,15 @@
// Auteur : Franck ALBARET
#include <stdio.h>
int main (void)
{
int Nbr,Reste;
puts ("Veuillez taper un entier :");
scanf ("%i",&Nbr);
Reste=Nbr%2;
if (Reste==0)
puts ("Le nombre est pair\n");
else
puts ("Le nombre est impair\n");
return 0;
}