Fixpoint getNats s n :=
  match n with 
    | O => nil
    | S n' => (s + n')%nat :: (getNats s n')
  end.

Lemma firstn_app : forall n (A : Set) (ls1 ls2 : list A), (n <= length ls1)%nat -> firstn n (ls1 ++ ls2) = firstn n ls1.