Answer Posted / sadikhasan palsaniya
int no=687;
int sum=0;
int temp;
while(no>0)
{
temp = no % 10;
sum += temp;
no = no/10;
}
System.out.println(sum);
Is This Answer Correct ? | 9 Yes | 0 No |
Post New Answer View All Answers
How to sort elements in a parallel array in java?
What is a pattern what is an anti pattern?
What are desktop procedures?
Can an anonymous class be declared as implementing an interface and extending a class in java programming?
Why is java architectural neutral?
How to restrict a member of a class from inheriting by its sub classes?
What is java algorithm?
Describe the term diamond problem.
What is method reference in java?
What is mean by encoding?
How to sort list of list in java?
What is final access modifier in java?
What is the difference between synchronized and synchronized block?
What is a cup of java?
What is the difference between the final method and abstract method?