Hi,
Below is my attempt to code the first example from Walder’s Theorems for free! paper.

I am not sure about what is being proved.

Using the notation from the paper does the proof establish a property of map, r, composition or the relationship between all three?

 

{-# LANGUAGE ExistentialQuantification #-}

import Data.Char

r :: forall a . [a] -> [a]

r = reverse

g :: Char -> Int

g = ord

 

(map g . r $ ['a','b','c']) == (r . map g $ ['a','b','c'])

 

Regards,

Pat

_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to