Write `arith_seq(a, d, n)` returning the first `n` terms with first term `a` and common difference `d`.