## The challenge

Given a non-negative integer, return an array / a list of the individual digits in order.

Examples:

 ``````1 2 3 `````` ``````123 => [1,2,3] 1 =>  8675309 => [8,6,7,5,3,0,9] ``````

## The solution in Python code

Option 1:

 ``````1 2 `````` ``````def digitize(n): return [int(d) for d in str(n)] ``````

Option 2:

 ``````1 2 `````` ``````def digitize(n): return list(map(int, str(n))) ``````

Option 3:

 ``````1 2 3 4 5 6 7 8 9 `````` ``````def digitize(n): lst = [] if n == 0: return  while n: n,r = divmod(n,10) lst.append(r) lst.reverse() return lst ``````

## Test cases to validate our solution

 `````` 1 2 3 4 5 6 7 8 9 10 11 12 `````` ``````import test from solution import digitize @test.describe("Fixed Tests") def fixed_tests(): @test.it('Basic Test Cases') def basic_test_cases(): test.assert_equals(digitize(123), [1,2,3]) test.assert_equals(digitize(1), ) test.assert_equals(digitize(0), ) test.assert_equals(digitize(1230), [1,2,3, 0]) test.assert_equals(digitize(8675309), [8,6,7,5,3,0,9]) ``````