I know this has already been asked in other thread but I recall a neater way of doing this:
so here is a code that i know how to unpack things:
list = [[1, "tom"], [4, "jane"], [2, "peter"], [5.5, "Ursala"]]
points=[p for p, n in list]
name=[n for p, n in list]
So I know this is how I extract lists from list of list
but i remember there is some neater way of doing this. It's something like.
points,name = list
it gives me however the error: too many values to unpack (expected 2)
is this method for dictionary? not applicable for list of list?