Hi, here is my code:

```
s =[]
def digit_sum(n):
if n >= 0:
n = str(n)
for i in n:
i = int(i)
s.append(i)
return sum(s)
```

Codecademy says 'your function fails on digit_sum(1000). It returns 12 when it should return 1.'

But when I launch it in visualizer like this:

```
s =[]
def digit_sum(n):
if n >= 0:
n = str(n)
for i in n:
i = int(i)
s.append(i)
print sum(s)
digit_sum(1000)
```

It prints '1'. What's wrong?