Question: Please use the Haskell Programming language Encoding and Decoding e Exercise: Define a function let2nat :: Char Int that converts a lower-case letter in the
Please use the Haskell Programming language

Encoding and Decoding e Exercise: Define a function let2nat :: Char Int that converts a lower-case letter in the range 'a' to 'z' into the corresponding natural number in the range 0 to 25. For example: let2nat'a' >let2nat z' 25 e Exercise: Define a function nat2let :: Int Char that performs the inverse function to let2nat. For example: > nat2let 0 > nat2let 25 . Exercise: Using let2nat and nat2let, define a function shift :: Int Char Char that applies a shift factor in the range 0 to 25 to a lower-case letter in the range'a' to 'z'. Characters outside this range, such as upper-case letters and punctuation, should be returned unshifted. Take care to ensure that your function wraps around at the end of the alphabet. For example: > shift 3'h' >shift 3 'z' >shift 3 'H
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
