InterviewSolution
Saved Bookmarks
| 1. |
Write a function expanding(l) that takes as input a list of integer l and returns True if the absolute difference between each adjacent pair of elements strictly increases. |
| Answer» DEF EXPANDING(l): for i in range(len(l)-2): if(l[i]>=l[i+1]): return FALSE return TrueExplanation:parameter l as input here | |