I have a list containing 1-5 lists in it. I want to return only the values that appear in all lists. I can easily throw an exception because there is only one list, but I cannot think about it when there are several (unknown number) lists. For instance:
[[1,2,3,4],[2,3,7,8],[2,3,6,9],[1,2,5,7]]
will only return 2, because this is the only list item that will be displayed in all sub-lists
How can i achieve this?
source
share