Martijn
·
Mar 20, 2011
·
Viewed 19.6k times
·
Source
I'd like to combine two lists. If I have the following two lists: {a,b,c,d} and {1,2,3,4} what do I need to do so that I get {{a,1}, {b,2}, {c,3}, {d,4}}?
Consider the following:
items = []
items.append("apple")
items.append("orange")
items.append("banana")
# FAKE METHOD:
items.amount() # Should return 3
How do I get the number of elements in the list items?