2. Write a function that takes two arguments, say n and x, and computes their power, xn. Use this to construct a function that squares its argument. Write a program that computes the square of 128.

module exercicio02
import StdEnv

3. Define the function isum :: Int -> Int which adds the digits of its argument. So, isum 1234 = 10 isum 0 = 0 isum 1001 = 2 You may assume that isum is applied to an argument which is not negative.

module exercicio04
import StdEnv

isum :: Int -> int
isum 1234 = 10
isum 0 = 0
isum 1001 = 2

Start = isum 0

4. Use the function isum to check whether a number can be divided by 9.

5. Define a function Max with two arguments that delivers the maximum of the two.

6. Define a function Min that has two arguments that delivers the minimum of the two.

7. Define a function MaxOfList that calculates the largest element of a list.

8. Define a function MinOfList that calculates the smallest element of a list.

9. Define a function Last that returns the last element of a list.

10. Define a function LastTwo that returns the last two elements of a list.

11. Define a function Reverse that reverses the elements in a list.

12. Define a function Palindrome which checks whether a list of characters is a palindrome, i.e. when you reverse the characters you should get the same list as the original.
{"ft_lang_label":"__label__en","ft_lang_prob":0.6826947,"math_prob":0.99122095,"size":1407,"snap":"2022-27-2022-33","text_gpt3_token_len":364,"char_repetition_ratio":0.19101924,"word_repetition_ratio":0.06896552,"special_character_ratio":0.26226014,"punctuation_ratio":0.1305842,"nsfw_num_words":0,"has_unicode_error":false,"math_prob_llama3":0.99806994,"pos_list":[0],"im_url_duplicate_count":[null],"WARC_HEADER":"{\"WARC-Type\":\"response\",\"WARC-Date\":\"2022-07-07T16:40:24Z\",\"WARC-Record-ID\":\"<urn:uuid:697f8a6a-8ff5-4102-becc-d59868cd44ab>\",\"Content-Length\":\"21252\",\"Content-Type\":\"application/http; msgtype=response\",\"WARC-Warcinfo-ID\":\"<urn:uuid:b02e24c3-2f3b-47c3-b4a7-9a736e7d9680>\",\"WARC-Concurrent-To\":\"<urn:uuid:2eebc248-3fd3-4c6e-926e-a3fcd6add029>\",\"WARC-IP-Address\":\"208.80.154.224\",\"WARC-Target-URI\":\"https://en.m.wikibooks.org/wiki/Concurrent_Clean/AnswersCH1\",\"WARC-Payload-Digest\":\"sha1:LTYSSN7NTQDB7BY2DNAOMDEYE7JIC2MJ\",\"WARC-Block-Digest\":\"sha1:HX3BLDOJH7PNYSNV6URGEFJOWGB6NUFE\",\"WARC-Identified-Payload-Type\":\"text/html\",\"warc_filename\":\"/cc_download/warc_2022/CC-MAIN-2022-27/CC-MAIN-2022-27_segments_1656104495692.77_warc_CC-MAIN-20220707154329-20220707184329-00635.warc.gz\"}"}