0 of 6 problems solved • 0%

Exercise prompt

Order Two Readings

You can choose which pair to return inside a branch. Every branch should keep the same meaning for the first and second positions.

Example

def mark(won): if won: return ("win", 3) return ("loss", 0) word, points = mark(True) print(word, points) # win 3

Both branches put the word first. The caller can unpack either result in exactly the same way.

Your task

Complete ascending(pair). Return the two readings as a tuple ordered from smaller to larger. Inputs may be negative or equal. Keep both readings in the result.