

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
Prepare for your exams
Study with the several resources on Docsity
Earn points to download
Earn points by helping other students or get them with a premium plan
Some concept of Building Programming Experience are Evaluation, List Procedures, Experience Modifying, Non-Collaborative, Syntactic Sugar, Thesaurus.Main points of this homework are: List Procedures, Procedure, Numbers, Returns, Stutter-List, Procedure, Original, Element, Returns, Procedure
Typology: Exercises
1 / 3
This page cannot be seen from the preview
Don't miss anything!


(square-list (list 1 2 3)) ;Value: (1 4 9) (square-list (list 3)) ;Value: 9 (square-list nil) ;Value: ()
(stutter-list (list 1 2 3)) ;Value: (1 1 2 2 3 3) (stutter-list (list 1) ;Value: (1 1) (stutter-list nil) ;Value: ()
(only-even (list 1 2 3 4 5)) ;Value: (2 4) (only-even (list 1 3 5 7 9)) ;Value: () (only-even nil) ;Value: ()
(only-even (list 2)) ;Value: (2) (only-even (list 3)) ;Value: ()
(add-lists (list 1 2 3) (list 4 5 6)) ;Value: (5 7 9) (add-lists nil nil) ;Value: ()
(palindrome-list (list 1 2 3)) ;Value: (1 2 3 2 1) (palindrome-list (list 1)) ;Value: (1)
(replace-elem (list 1 2 1 2 1 2) 1 5) ;Value: (5 2 5 2 5 2) (replace-elem (list 1 2 3 4) 3 7) ;Value: (1 2 7 4) (replace-elem (list 1 2 3) 7 77) ;Value: (1 2 3)
(list-average (list 1 2 3)) ;Value: 2 (list-average (list 1))