[Haskell-cafe] Coding katas/dojos and functional programming introduction

Alexey Shmalko rasen.dubi at gmail.com
Fri Apr 17 11:38:25 UTC 2015


When I was a Haskell beginner I was fascinated by writing even a simple CSV
parser. It was so clear after flex/bison or parsing by hand in C++. The
other cool thing in Haskell is writing JSON parsers with aeson. They also
really short and expressive.

Regards,
Alexey

On Fri, Apr 17, 2015 at 10:47 AM, Ernesto Rodriguez <neto at netowork.me>
wrote:

> I agree with the approach. I have never done a intro to FP but I think
> parser combinators couod be a good start. U begin by showing the high level
> interface, I mean learning how to write simple parsers using for instance
> Parsec is.easy and one immediately sees the elegance and simplicity that
> approach has over say yacc. Then u guide them on implementimg a own basic
> parser combinator library which in my opinion is not out of this world with
> a good guideance. That way they see that such a powerful tool aint dark
> magic with FP.
>
> Anyways good luck with your workshop.
>
> Cheers,
>
> N.
> On Apr 16, 2015 7:25 AM, "Raphael Gaschignard" <dasuraga at gmail.com> wrote:
>
>> Is this aimed for FP beginners who already know something like Java? I
>> think the thing to do here would be to come up with some tasks that are
>> genuinely tedious to write in a Java-esque (or Pascal-like) language, and
>> then present how FP solutions are simpler.
>>
>>   I'm of the opinion that FP succeeds not just because of the tenants of
>> FP, but because most of the languages are terse and have code that is
>> "pretty". Showing some quick things involving quick manipulation of tuples
>> (basically a bunch of list processing) could show that things don't have to
>> be complicated with a bunch of anonymous classes.
>>
>>   Anyways, I think the essential thing is to present a problem that they,
>> as programmers, have already experienced. The big one being "well these two
>> functions are *almost* the same but the inner-part of the function has
>> different logic" (basically, looking at things like map). Open up the world
>> of possibilities. It's not things that are only possible in Haskell/Scheme
>> (after all, all of these languages are turing complete so..), but they're
>> so much easier to write in these languages.
>>
>> On Thu, Apr 16, 2015 at 7:41 AM Mike Meyer <mwm at mired.org> wrote:
>>
>>> On Wed, Apr 15, 2015 at 5:28 PM, Gautier DI FOLCO <
>>> gautier.difolco at gmail.com> wrote:
>>>
>>>> 2015-04-15 19:15 GMT+00:00 Mike Meyer <mwm at mired.org>:
>>>>
>>>>> Well, functional programming is very much like an elephant.
>>>>>
>>>>
>>>> I have the same thought about OOP some years ago, them I discovered
>>>> then first meaning of it and all was so clear and simple. My goal isn't to
>>>> teach the full power of FP, my goal is to give them inspiration, to suggest
>>>> that there is a wider world to explore.
>>>>
>>>
>>> Just clarify, this is a reference to the fable of the blind men and the
>>> elephant. What you think it is like will depend on how you approach it.
>>> _______________________________________________
>>> Haskell-Cafe mailing list
>>> Haskell-Cafe at haskell.org
>>> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe
>>>
>>
>> _______________________________________________
>> Haskell-Cafe mailing list
>> Haskell-Cafe at haskell.org
>> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe
>>
>>
> _______________________________________________
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
> http://mail.haskell.org/cgi-bin/mailman/listinfo/haskell-cafe
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.haskell.org/pipermail/haskell-cafe/attachments/20150417/9d871291/attachment-0001.html>


More information about the Haskell-Cafe mailing list