Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
even=[2,4,6,8]
odd=[1,3,5,7,9]
num= *even,*odd
print (list(num))
#Output:[2, 4, 6, 8, 1, 3, 5, 7, 9]
#or
num=[*even,*odd]
print (list(num))
#Output: [2, 4, 6, 8, 1, 3, 5, 7, 9]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment