: nat) (hn : idx < length l) : A := match l with | [] => _ | h :: t => match idx with | O => h | S idx' => nth_safe t idx' _ end end. 10 l = []なので hn : idx < length []
: nat) (hn : idx < length l) : A := match l with | [] => _ | h :: t => match idx with | O => h | S idx' => nth_safe t idx' _ end end. 13 l = h :: t, idx = S idx'なので hn: S idx' < length (h :: t) ゴール:idx' < length t