#include<stdio.h>
#include<conio.h>
void main()
{
int n, d1, d2, d3, d4, d5, sum;
clrscr();
printf("Enter a five digit number : ");
scanf("%d",&n);
d1 = n % 10;
n = n / 10;
d2 = n % 10;
n = n / 10;
d3 = n % 10;
n = n / 10;
d4 = n % 10;
n = n / 10;
d5 = n % 10;
sum=d1+d2+d3+d4+d5;
printf("The sum of the digits is : %d",sum);
getch();
}
Home       |      About Us       |     Portfolio       |      Services       |       Career        |    Contact Us       |      Industrial Training        |      Achievement 
Corporate Services
  Web Design and development
  Web Promotion (SEO)
  Multimedia/CD Presentation
  Software development

  E.Commerce

Training@balujalabs

  Software Courses
  Hardware Courses
  Networking.Courses
  Mobile Repairing Courses
  UGC Degrees
Student Corner
 Programming & Projects
 Placement Papers
 Project Ideas
 Synopsis Ideas

  Franchise Section

 Administrator
Franchise Inquiry
 
 

To find sum of the digits of a number

 

 

 

 

 

 

 

 

 

                                                                                                                                          

1
2
3 To demonstrate the use of scope resolution operator
4 To find circumference of a circle.
5 To find hexadecimal and octal value of a number.
6 To convert a temperature from Fahrenheit to degree cells.
7 To find sum of the digits of a number.
8 To obtain gross salary by calculating dearness allowance and house rent.
9 Program to convert kilometers to meters.

 

     
Home       |      About Us       |     Portfolio       |      Services       |       Career        |    Contact Us       |      Industrial Training        |      Achievement