(cap-length n x) → *
Function:
(defun cap-length (n x) (declare (xargs :guard (natp n))) (let ((__function__ 'cap-length)) (declare (ignorable __function__)) (if (< (lnfix n) (len x)) (take n (list-fix x)) x)))
Theorem:
(defthm cap-length-of-nfix-n (equal (cap-length (nfix n) x) (cap-length n x)))
Theorem:
(defthm cap-length-nat-equiv-congruence-on-n (implies (nat-equiv n n-equiv) (equal (cap-length n x) (cap-length n-equiv x))) :rule-classes :congruence)