Here is my code. I cannot for the life of me find out why it's not unpacking the *args to a list argslist. When I print the argslist immediately after that, it only reads '1'. This is the first time I've worked with *args. I've looked over the Python documentation and several articles and still don't understand why this isn't working.
def checkio(*args):
args_list = list(range(*args))
print (args_list)
nums = []
for item in args_list:
nums.append(float(item))
nums.sort()
diff = abs(nums[-1] - nums[0])
return diff
Created at: Sept. 15, 2015, 8:49 p.m.; Updated at: Dec. 23, 2015, 5:50 p.m.