Functional Programming.
(a) Write a Scheme procedure reduce that reduces a list by removing its first and last component: (b) Write a Scheme procedure rotate_right that transforms a list as follows: (c) Write a Scheme procedure rotate left that transforms a list as follows: (d) Write a Scheme function (count e Ist) that counts the number of times the element e occurs in > (reduce ‘(1 2345) (2 3 4) > (rotate_right ( 23 45)) (5 1
OR
OR