Question: ( definec in ( a :all x :tl ) :bool ( and ( consp x ) ( or ( = = a ( car x
definec in a :all x :tl :bool
and consp x
or a car x
in a cdr x
definec ap x y :tl :tl
if endp x y
cons car x
ap cdr x y
definec rv x :tl :tl
if endp x x
ap rv cdr x
list car x
definec remdups x :tl :tl
cond endp x x
in car xcdr xremdups cdr x
t cons car x
remdups cdr x
; You get this property for free, since we did it in class. See
; lproof for the proof checker proof. You will have to do similar
; proofs for this homework.
property apassoc x y z :tl
ap ap x y z
ap x ap y z
; The first two lemmas are proof checker proofs of inap using
; different induction schemes.
Lemma inap:
tlp xtlp y
in a ap x y
v in a xin a y
Proof by: Induction on in a x
XXX
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
