(define factorial
 (lambda (n)
  (if (= 0 n) 1
   (* n (factorial (- n 1))))))

(factorial 6)

(define factit
 (lambda (n)
  (letrec
    ((fit
      (lambda (n acc)
        (if (= n 0) acc (fit (- n 1) (* n acc))))))
   (fit n 1))))

(factit 6)
