
I'm teaching an introductory 12-week class on Haskell - BinRoo
http://shuklan.com/haskell
======
rheeseyb
"Nothing is evaluated unless necessary

head (sort ls)

The list will only be sorted enough to find the minimum"

This may be technically true, but is a pretty bad example with much hand
waving - what exactly does it mean to be "sorted enough to find the minimum"
given that Haskell uses a merge sort implementation internally?

A better example of Haskell's lazy nature (taken from the Learn You A Haskell
book) would be:

take 10 (repeat 5) - it's very easy to comprehend taking the first 10 elements
of an infinitely long list without needing to compute the entire list.

~~~
Kutta
Yep, the "sort only to get head" trick only works fully with selection sort,
where it reduces complexity from O(n^2) to O(n) (reduces to a simple max/min).
But it also confers some advantage in the case of standard merge sort: the
last two sorted sublists will not be merged.

Regarding "repeat", I find it pretty much awesome that it is implemented as a
_circular linked list with a single element_ , as in:

    
    
        repeat x = xs where xs = x : xs
    

which ensures that it will take up constant space no matter how "far" in it is
evaluated.

------
Silhouette
Nice presentation. Friendly notes:

1\. Ctrl+Shift+K opens the web console in Firefox, not your secret notes.

2\. Please don't present naive "quicksort" in Haskell as equivalent to a real
quicksort unless you're also going to prove that the cute Haskell example is
as efficient in all senses as the in-place C implementation. (Good luck with
that, as my American friends say.)

~~~
eranation
Great mobile support by the way. But regarding secret notes, although
reveal.js and bootstrap looks great on mobile, there is no way that I could
find to view the secret note on Android chome...

~~~
pandeiro
Maybe on Android 4.x, but on older devices, it's useless. The slides do not
auto-fit the screen.

------
nanook
I'm having a hard time keeping up with all these awesome classes.

Coursera's PL class is starting in a few days:
<https://www.coursera.org/course/proglang>

Brown's Intro to PL class: <http://cs.brown.edu/courses/cs173/2012/Videos/>

------
why-el
Great work so far. I like the organization. Any plans to release video
lectures?

~~~
eLobato
+1 for videos. They make it much more enjoyable but it can be a lot of work :(
Are you going to publish quizzes and assignments?

------
pohl
Awesome! Thanks for posting about this. I just started Erik Meijer's
13-lecture video series on Channel 9, and look forward to bolster my learning
with your course.

 _Every slide has a secret note_

Any idea how to show that on something like an iPad? Once per day to see the
alt text on xkcd is already too much to bear.

~~~
JoshTriplett
> Once per day to see the alt text on xkcd is already too much to bear.

Try the mobile site, m.xkcd.com; it has a clickable "alt-text" link to reveal
the alt text in-page.

------
akurilin
Will you be sending out email reminders when every new lecture is posted? I'd
love to follow along, but find it very hard to remember all of the classes I
subscribed to.

~~~
BinRoo
Yup. Please enroll so that I keep everyone up to date
[https://docs.google.com/spreadsheet/viewform?formkey=dGtrcXZ...](https://docs.google.com/spreadsheet/viewform?formkey=dGtrcXZJUGx1QkpqVnh1WlRpTDR1VUE6MQ)

~~~
reirob
enrolled.

------
gtani
May want a few pointers to a huge number of tutorials and books:

<http://www.haskell.org/haskellwiki/Meta-tutorial>

<http://www.haskell.org/haskellwiki/Tutorials>

Unfortunately, the wiki for books is out of date, I would suggest looking at
those by Thompson (3rd ed), Hutton, Bird (Pearls of Functional), Hudak:
<http://haskell.cs.yale.edu/testnewtemplate/>

also lots of cheats:

<http://qiita.com/items/008c8a3859d432c39823>

------
lawn
Yet another attempt/excuse for learning Haskell!

------
angrycoder
Really? A picture of a kid with Down's Syndrome wearing a Superman outfit?

~~~
mahmud
And the original image has a Lisp column, conveniently removed from this one
;-)

<http://kuehnast.com/s9y/uploads/langs.jpg>

------
xiaoma
Very nice. Was this of your own initiative or was it the department?

~~~
BinRoo
Thank you! Yes, this was my own initiative.

------
btian
Looks like it's going to be a great course! On an unrelated note, how did you
generate the slides? They're very cool.

~~~
BinRoo
Here's my source code <https://github.com/BinRoot/Haskell-Lectures>

------
nnq
please, replace the slide 6 pic with this one:
<http://4.asset.soup.io/asset/0750/2820_15d5_960.jpeg> (you can't just pretend
Lisp doesn't exist, you know ;) )

------
bmcfeeley
Was just hit with the desire to learn more about Haskell this weekend, after
stumbling on some notes from a Language Paradigms class in school...can't wait
to check this out!

------
misframer
I'm taking this course next semester at UVa. Can't wait!

~~~
BinRoo
Get excited!

------
misleading_name
Awesome. Learning Haskell has been on my list for a long time, and I really
appreciate that both books are available for free online. Thanks!

------
l_tonz
first time I learned Haskell it was great; gave me a new insight on how to
think differently while coding other languages.

------
nicholasjarnold
Favorite pairs from the 'X as seen by Y' slide: {{Java, C}, {C, Java}, {PHP,
Java}, {Ruby, Java}, {PHP, Ruby}}

~~~
bgilroy26
I don't understand the Ruby as seen by PHP square

~~~
wyclif
There is some complexity to that meme, but put very simply it illustrates that
PHP people sometimes view Rubyists as either cultic and/or atheistic about
programming religion.

------
shocks
This looks awesome. Thanks! I will definitely be following along.

------
mitchi
Nice presentation. Did you use a tool to create the slides?

------
jrogers65
Could you make these available for download, by any chance?

~~~
BinRoo
Try this feature <https://github.com/BinRoot/Haskell-Lectures#pdf-export>

Let me know if it works well.

~~~
jrogers65
Very interesting way to solve the problem. It works great. Thank you!

------
asimjalis
It’s beautiful. How did you create the slides?

------
Jasdev
enrolled!

------
shocks
Beautiful slides. :)

