Skip to content

Instantly share code, notes, and snippets.

Created January 18, 2021 16:03
What would you like to do?
from itertools import starmap
def multiply(x,y):
return x*y
#Returns a starmap object
print (result)#Output:<itertools.starmap object at 0x00CAE4D8>
#converting starmap object to list() constructor.
print (list(result))#Output:[11, 44, 99, 176]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment