TypeScript基本から応用まで 100本ノック
サンプル
Narrowing(型の絞り込み) - 問題 9