Code for PROGRAM TO FIND SUM OF ALL INTEGER WHICH IS > 100 AND < 200 AND WHICH IS DIVISIBLE BY 7 in C Programming
#include<stdio.h>
#include<conio.h>
void main()
{
int i,sum = 0;
clrscr();
for(i = 100;i <= 200 ; i++)
{
if (i % 7 == 0)
sum = sum + i;
}
printf("\n Sum of all no between 100 and 200 ");
printf("which is divisible by 7 is :: %d",sum);
getch();
}
/*
********
OUTPUT
********
Sum of all no between 100 and 200 which is divisible by 7 is :: 2107
*/