Twilio | OA | India | 2021
1129

The entire test was for 120 mins and had 5 questions via Hackerrank.

a. Find sum of all elements in the array.
b. Given a list, find all the pairs of elements with the least difference.
c. A partial filled class in which we had to fill the constructor, override compareTo method based on question.
d. Implement a class to return the reverse of a string in lower case if it satisfied certain conditions, else throw IllegalArgumentException with a particular message.
e. Find the number of commitees of 3 that can be formed, if each committee should have atleast 1 man & 1 woman. Input is total number of women & men to select from.

Questions were mostly easy. Able to solve most except my implementation of b had 1 test case which timed out. Hardly took 45 minutes to complete.

Comments (3)