Phonepe Online Coding Round (On-Campus Intern 2021)

Platform for online coding round was at https://doselect.com/ .
There were a total of 3 questions.
Time Limit : 90 mins.
Date : 30th August 2021

Coding Questions

  1. A frog want to cross a river of lenght n.There were several stones at each unit distance in the river on which frog can jump.Maximum jump can be of distance k.Stones are represent in an array as 'L' and 'R'.If you are at stone L'at index 'i' then you can jump only in the left direction(i.e towards starting point) to index in range : [max(0,i-k),i-1] and if you are stone R'then you can jump only in right direction to index in range : [i+1,min(i+k,n+1)].
    Frog was not at any stone in the starting.You Need to calculate minimum value of k such that frog can reach to index n+1(i.e cross the river).
    Example :
    Stones : [L,R,L,R]
    Ans : k=2
    [Hint : Use Binary seach on k.]

  2. Second question was exact same as : https://codeforces.com/problemset/problem/1526/B

  3. Third question was exact same as : https://leetcode.com/problems/minimum-speed-to-arrive-on-time/

People who solved all 3 quesitions were shortlisted to next round. In my experience I felt coding round to be on easier side because of repeated questions.

Comments (2)