Oops, try again. Your function fails on digit_sum(434). It returns 44 when it should return 11.
I keep thinking that my code should take the argument number and convert it to a string and store it in the variable numbers. Then I used a for loop to go through each string(s) in the variable numbers and then convert it to a integer and then each integer(s) + the next integer and then return the result. Somehow it equals 44 and not 11 when the computer tests it on "434". I guess I don't understand why it does that and what I am doing wrong?
def digit_sum(number): numbers = str(number) for s in numbers: int(s) result = s + s return result