fork download
  1. # your code goes here
  2. A = [[[1,2,3],[4]],[[1,4],[2,3]]]
  3.  
  4. r = []
  5.  
  6. for list in A:
  7. f = True
  8. for item in list:
  9. if sum(item) > 5:
  10. f = False
  11. if f:
  12. r.append(list)
  13.  
  14. print r
Success #stdin #stdout 0s 23304KB
stdin
Standard input is empty
stdout
[[[1, 4], [2, 3]]]