mirror of
https://codeberg.org/DansLeRuSH/c-plus-plus-exercises.git
synced 2024-11-22 03:28:09 +00:00
27 lines
480 B
C++
27 lines
480 B
C++
|
// Auteur : ALBARET Franck
|
|||
|
#include <stdio.h>
|
|||
|
#include <conio.h>
|
|||
|
|
|||
|
int main (void)
|
|||
|
{
|
|||
|
int Nbr;
|
|||
|
int i=0;
|
|||
|
int Max=0;
|
|||
|
clrscr();
|
|||
|
puts ("entrez un chiffre, entrez un z<>ro pour arr<72>ter. \n");
|
|||
|
scanf("%i",&Nbr);
|
|||
|
while (Nbr!=0)
|
|||
|
{
|
|||
|
puts ("entrez un chiffre, entrez un z<>ro pour arr<72>ter. \n");
|
|||
|
scanf("%i",&Nbr);
|
|||
|
if (Nbr>Max)
|
|||
|
{
|
|||
|
Max=Nbr;
|
|||
|
}
|
|||
|
i=i+1;
|
|||
|
}
|
|||
|
printf("Le nombre maximum est %i. \n",Max);
|
|||
|
getch();
|
|||
|
return 0;
|
|||
|
}
|