Sum of Digits of a Five Digit Number Discussions | C | HackerRank

Sum of Digits of a Five Digit Number

  • + 0 comments

    \ while(n>0){ int a = n%10; sum=sum+a; n=n/10; } use while loop