Use list.extend not list.append:
The difference between extend and append is that append appends the object passed to it as it is. While extend expects that item passed to it to be an iterable(list, tuple,string, etc) and appends it's items to the list.
Using append we can append any type of object; i.e iterable or non-iterable.
>>> lis = [1,2,3]
>>> lis.append(4) #non-iterable
>>> lis.append('foo') #iterable
>>> lis
[1, 2, 3, 4, 'foo']
But extend behaves differently and actually appends the individual items from the iterable to the list.
>>> lis = [1,2,3]
>>> lis.extend('foo') #string is an iterable in python
>>> lis
[1, 2, 3, 'f', 'o', 'o'] #extend appends individual characters to the list
>>> lis.extend([7,8,9]) #same thing happend here
>>> lis
[1, 2, 3, 'f', 'o', 'o', 7, 8, 9]
>>> lis.extend(4) #an integer is an not iterable so you'll get an error
TypeError: 'int' object is not iterable
Your Code
>>> distance = [[]]
>>> distance[-1].extend ([0,1,2,3.5,4.2])
>>> distance
[[0, 1, 2, 3.5, 4.2]]
This returns:
[[0, 1, 2, 3.5, 4.2]]
If you wanted to do this then there's no need to append the empty [] and then call list.extend, just use list.append directly:
>>> ditance = [] ##declare my array
>>> distance.append([0,1,2,3.5,4.2])
>>> distance
[[0, 1, 2, 3.5, 4.2]]