Amdocs Interview Question

Linear and non linear DS