Bonjour defati
je viens de faire ton exercice en modifiant un peu ton programme:
#include <stdio.h>
#include <stdlib.h>
main( )
{
int x, j, h, m, s, r, t,u;
printf("introduisez un nombre entier:");
scanf("%i",&x);
s= x%60;
m= x/60;
h=x/3600;
r=x%3600;
j=x/86400;
t=x%86400;
if (x<60)
{s=x;
printf("0 j,0 h,0 m et %d s\n",s);}
else
if(x>=60 && x<3600 )
{printf(" 0 j, 0 h, %d m, %d s\n",m,s);}
else
if (x>=3600 && x<86400 )
{m=r/60;
printf(" 0 j, %d h, %d m, %d s\n",h,m,s);}
else
if (x>=86400)
{h=t/3600;
u=t%3600;
m=u/60;
printf("%d j,%d h,%d m,%d s\n",j, h, m, s);}
system("pause");
}
bon courage pour la suite