<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content="text/html; charset=iso-8859-1" http-equiv=Content-Type>
<META name=GENERATOR content="MSHTML 8.00.6001.19019">
<STYLE></STYLE>
</HEAD>
<BODY bgColor=#ffffff>
<DIV><FONT size=2 face=Arial>In <EM>Learn You a Haskell for Great Good!,</EM> 
the author Miran Lipovaca&nbsp;indicates that to understand Monads you need to 
know Functors...</FONT></DIV>
<DIV><FONT size=2 face=Arial>So, I noticed the following:</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>class Functor f where</FONT></DIV>
<DIV><FONT size=2 face=Arial>&nbsp; fmap::(a-&gt;b)-&gt;f a-&gt;f b</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>instance Functor [] where</FONT></DIV>
<DIV><FONT size=2 face=Arial>&nbsp; fmap = map</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>map::(a-&gt;b)-&gt;[a]-&gt;[b]</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>if [] is substituted for f in the class definition 
of Functor the following is obtained</FONT></DIV>
<DIV><FONT size=2 face=Arial>class Functor [] where</FONT></DIV>
<DIV><FONT size=2 face=Arial>&nbsp; fmap::(a-&gt;b)-&gt;[]a-&gt;[]b</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>my questions are:</FONT></DIV>
<DIV><FONT size=2 face=Arial>&nbsp; 1. is this substitution ok?</FONT></DIV>
<DIV><FONT size=2 face=Arial>&nbsp; 2. is []a = [a]?</FONT></DIV>
<DIV><FONT size=2 face=Arial>&nbsp; 3. is []b = [b]?</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>if 2. and 3. are valid then the following is 
obtained:</FONT></DIV>
<DIV><FONT size=2 face=Arial>&nbsp; fmap::(a-&gt;b)-&gt;[a]-&gt;[b]</FONT></DIV>
<DIV><FONT size=2 face=Arial>which is the same as map type and therefore: fmap = 
map. QED.</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>Can you please answer questions 2 and 3 
above?</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial>Thank you</FONT></DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV>
<DIV><FONT size=2 face=Arial></FONT>&nbsp;</DIV></BODY></HTML>