Skip to main content
Journey Uncommon Logo
JourneyUncommon
hardTypeScriptconditional-type distributionSingle-choice MCQ1 views

Wrapping the checked type in a single-element tuple changes the result of these two conditionals. Which pair of results is correct?

type Distrib<T> = T extends never ? 1 : 2; type NoDistrib<T> = [T] extends [never] ? 1 : 2; type A = Distrib<never>; type B = NoDistrib<never>;