/* Declaramos Librerias */
#include
#include
main() /* Iniciamos Programa */
{
int a,b,c,d,e; /* Declaramos enteros */
printf("Numero 1:"); /* Imprimimos en pantalla */
scanf("%d",&a); /* Escaneamos un valor y lo guardamos en a */
printf("\nNumero 2:");
scanf("%d",&b);
printf("\nNumero 3:");
scanf("%d",&c);
printf("\nNumero 4:");
scanf("%d",&d);
printf("\nNumero 5:");
scanf("%d",&e);
/* La logica es: Si el residuo de a entre 2 es 0, es par y lo imprime, si no no. Despues, si el residuo de a entre 2 es 1, es impar y lo imprime*/
if (a%2==0)
printf("%d",a);
if (b%2==0)
printf("%d",b);
if (c%2==0)
printf("%d",c);
if (d%2==0)
printf("%d",d);
if (e%2==0)
printf("%d",e);
if (a%2==1)
printf("%d",a);
if (b%2==1)
printf("%d",b);
if (c%2==1)
printf("%d",c);
if (d%2==1)
printf("%d",d);
if (e%2==1)
printf("%d",e);
getch();
return 0;
}
One of the most astonishing old town on the planet Old City of Jerusalem
-
Jerusalem is perhaps the most established city on the planet . By measuring
its history and its multifaceted nature, on the off chance that we think
about ...
Hace 5 años
0 comentarios:
Publicar un comentario