Hacker Read top | best | new | newcomments | leaders | about | bookmarklet login

Question: why don't I see sites like "99 trivial, first-week-of-class problems solved in C?" If I have to stop and think about how to do the things on that page, or consult a web page to find out how to express them, then the language I'm working in is simply broken.

What problem(s) do software developers typically have that are solved by working in functional languages?



view as:

I think it's because these things are hard to do in C. The first week of C is all about dealing with the language rather than solving problems. Any problem can be solved in a functional language, so I'm not sure what you're asking.

You've never seen a beginner C tutorial? You seem to imply that just because there's teaching material out there for beginners, that somehow means the language is intractable. Every language that wants users should have beginner-level material.

One difference is that basic C/C++/Java books are always attempting to teach programming or even discrete/logical thinking at the same time. Most of the basic books I've seen start with some silly over-extended analogy for procedures, loops, etc. along with a few examples of supposed "real-world" problems.

Once you know how to program, learning lesser-known languages like Haskell or Lisp is all about learning how to do basic things differently. For example, The Little Schemer taught me to think of iteration in terms of recursion and vice-versa. Haskell and Lisp books (at least good ones) don't teach you how to make a virtually featureless pizza ordering system or a recipe database, they teach you a new way to think about the building blocks of programs.

These "99 question" lists aren't supposed to be brainteasers or math puzzles like, say, Project Euler, they're supposed to be illustrative of what sets these languages apart from the more commonly-known C-style languages.


Legal | privacy