Loading...

Rank Metrics

A medium Python interview practice problem on DataDriven. Write and execute real python code with instant grading.

Domain
Python
Difficulty
medium

Problem

A top-N metrics report needs key-value pairs sorted by value from highest to lowest. Return a list of [key, value] pairs sorted by value in descending order.

Practice This Problem

Solve this Python problem with real code execution. DataDriven runs your Python code in a sandboxed Docker environment and grades it instantly.