Check whether a number is divisible by 7 and 10 | C-Program

Divisible by 7 and 10:

Code:

#include<stdio.h>

void main()

{

    int n;

    printf("Enter a number:\n");

    scanf("%d",&n);

    if(n%7==0 && n%10==0)

    {

        printf("%d is divisible!",n);

    }

    else

    {

        printf("%d Not divisible!",n);

    }

    getch();

}

Output:


Comments

Popular posts from this blog

TOP 10 PROGRAMMING LANGAUAGES COMMING 2021 | ARTICLE

Write a C-program to swap two number:

Print Fibonacci Series using Recursion | C program :