Back To C Loops Index
continue statement results in termination of running iteration
//program to input a number and find sum of digits of the number #include
#include
void main() { int num,digit,rev=0; int sum=0; clrscr(); printf("\nenter the number"); scanf("%d",&num); do { digit=num%10; sum=sum+digit; num=num/10; }while(num!=0); printf("\nthe sum of numbers is %d",sum); getch(); }