What would you like to do?

Program in c language to find the sum of digits?

already exists.

Would you like to merge this question into it?

already exists as an alternate of this question.

Would you like to make it the primary and merge this question into it?

exists and is an alternate of .

#include <stdio.h>
void main()
int digi,num,i,sum=0;

printf("Enter the number of digits:");

printf("The sum of digits entered is %d",sum);
7 people found this useful
Thanks for the feedback!

C program to find sum of two sparse matrices?

 #include  #include    typedef struct node  {  int column;  int value;  int row; 

Write c program to find sum of two numbers?

/*use "c-free" compiler*/ #include main() { int a,b,c; printf("enter the value of a & b"); scanf("%d%d",&a,&b); c=a+b; printf("sum of the two numbers is a+b- %d",c); g

Write a c program to compute the sum of digits of a given integer number?

int sumDigits(int n) {   int sum = 0;    while( n > 0 ) {   sum += (n % 10); // add last digit of n to sum   n /= 10; // divide n by 10 to "chop off" the la

C program to find sum of n numbers?

include #include main() { int num, n,sum=0,i=0; printf("enter the number of elements to be added "); scanf("%d",&n); printf("enter %d numbers",n); while(i

C program to find sum of digits of a number using function?

#include #include void main() { int sumdig(int); int n,sum,d,f,rev=0; clrscr(); printf("enter the number"); scanf("%d",&n); sum=sumdig(n); printf("%d",sum)

Write a java script program to find sum of the digits of a given integer?

import java.util.*;   class SumOfDigits {  public static void main(String args[]) {  int sum = 0;  System.out.println("Enter

Program to find sum of two numbers in VB.NET language?

Option Explicit Dim a as integer Dim b as integer Dim c as integer Dim result as integer a=val(text1.text) b=val(text2.text) c=val(text3.text) result=a+b+c '

C plus plus program to find the sum of the digits using constructor?

Constructors cannot return values so the only paractical way of  achieving this would be to supply an output parameter to the  constructor. But what exectly are you construc

Write a program to find the sum of the digits and reverse of the digits using inheritance?

There is a far easier way to implement the required functionality than using inheritance. However, to answer the question, here's one possible solution that makes use of inher