Get Average Standing
Problem Overview
- Compute each player's average standing across car game races from event records.
- Input: d players and records [race_id, player_id, player_time]; Output: for each player, p and q of the reduced average-standing fraction, or -1 and -1 if they never raced.
- For each race, rank by increasing finish time; if times tie, the lower player id receives the worse rank.
- Real-world domain: Amazon Games result analysis; an Amazon interviews coding interview problem and interview question.
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Input Variables
Execution Result:
