How to write a C program to find out whether it is even or odd?

#include
int main()
{
        int num;
        scanf("%d", &num);
        if(num %2 ==0)
        {
              printf("Even");
        }
        else
        {
              printf("Odd");
        }


}






Related tags: #c, #cprogramming, #programming, #github

Comments