Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

;; LISP Assignment #1 (100 pts) ;; ;; 1. (25 puts) write a recursive function named MYMEMBER that takes an ATOM (atm) and a LIST

;;LISP Assignment #1 (100 pts) ;; ;; 1. (25 puts) write a recursive function named MYMEMBER that takes an ATOM (atm) and a LIST (lst) ;; and returns the ATOM if it is a MEMBER, otherwise NIL ;; ex. (MYMEMBER D (A B C D E F G) returns => D ;; ex. (MYMEMBER H (A B C D E F G) returns => NIL ;; ;; 2. (25 pts). write a recursive function named MYFACT that takes an INTEGER and returns that many ;; factorial values on a list ;; ex. (MYFACT 4) returns => (24 6 2 1) ;; ;; 3. (25 pts). write a recursive list reversal - given ;; ex. (MYREVERSE (a b c)) returns => (c b a) ;; ;; 4. (25 puts). write a recursive double-odd, MY-DOUBLE-ODD that doubles the odd values and leaves ;; the even values alone ;; ex. (MY-DOUBLE-ODD (1 2 3 4 5 6)) returns => (2 2 6 4 10 6) ;;

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

The Structure Of The Relational Database Model

Authors: Jan Paredaens ,Paul De Bra ,Marc Gyssens ,Dirk Van Gucht

1st Edition

3642699588, 978-3642699580

More Books

Students also viewed these Databases questions

Question

=+ 4. Why should policymakers think about incentives?

Answered: 1 week ago

Question

=+ 2. What is the opportunity cost of seeing a movie?

Answered: 1 week ago

Question

=+ what roles should government play in them ?

Answered: 1 week ago