All challenges
Code AnalysisHard 45s

typing Union

What is the output?
Starter code
from typing import Union, get_type_hints
def f(x: Union[int, str]): pass
hints = get_type_hints(f)
print(hints['x'].__origin__.__name__)

Think you can answer under pressure?

Get matched and answer live questions in 3-minute 1v1 battles. Elo ranking, badge tiers and bragging rights on the line.

Play this in a 3-minute battle