1065 - Even Between five Numbers

Problem Link


A Solution in c


#include<stdio.h>
int main()
{
    int i, j, n = 0;
    for(i = 1; i <= 5; i++)
    {
        scanf("%d", &j);

    if(j%2 == 0)

        n = n + 1;
    }
    printf("%d valores pares\n", n);
    return 0;
}






No comments

Theme images by Jason Morrow. Powered by Blogger.