← Questions
Research OA: best value ratio, shuttle trips and grid commands
0
I was asked this
No reports yet. Sign in to say where you were asked it.
A multi-part online assessment.
- Given
ratingsandprices, return the index with the highest rating-to-price ratio, choosing the smaller index on ties. Compare the fractions exactly, without floating point. - A traveller must make a number of round trips between A and B. Departure times from A to B and from B to A are given as sorted lists. Starting at time 0 and always taking the first departure not earlier than the current time, when are the trips finished?
- Apply a list of commands (such as swapping rows or columns) to a 2D array in order and return the result.
No official answer yet. Write yours on the right and run it.
Nothing published yet.
Sign in to submit your code; every attempt is kept here.
Write and test your solution herePython in your browser, the question's tests level by level, every submission kept for you.Sign in to start coding
