+ 1
nums = [1, 2, 3] print(nums * 3) >>>123123123 how to revise and get >>>246
2 Answers
+ 3
new_nums = [2*x for x in nums]
0
Probably not the best technical solution, but one my brain could follow:
nums = [1,2,3]
help = (nums[0]*100 + nums[1]*10 + nums[2])
print (help*2)