dannyvega
Newbie level 3
c++ math problem
I need to make a program that takes a number like 117
and adds the individual digits together (1+1+7) which equals 9
and divides it by 9 to see if the number is divisable by 9
but I don't know how to isolate each digit in order to add them together.
Can anyone help me
I need to make a program that takes a number like 117
and adds the individual digits together (1+1+7) which equals 9
and divides it by 9 to see if the number is divisable by 9
but I don't know how to isolate each digit in order to add them together.
Can anyone help me