HNHacker News
TopNewBestAskShowJobs

rkts

277 karma · joined August 16, 2007

submissionscomments
rkts··on Real World Haskell
Sorry, I didn't mean to imply that Haskell is only used for writing toy programs. I meant that Haskell people gravitate toward problems that are functional in nature. Many such programs are useful, though rarely in isolation.

If you're wondering where the idea comes from, here's an example. There is a thread on Facebook titled "What have you made using Haskell?"

http://www.facebook.com/topic.php?uid=2213713570&topic=2...

Here are the responses:

1. HAppS (a web thingy)

2. A minesweeper clone

3. A preprocessor for POV-Ray source files

4. A program to prove graph isomorphisms

5. A parser for boolean logic sentences

6. A lambda expression evaluator with alpha equivalence testing

7. A hyperbolic raytracer

8. An image regression program

9. A program that finds equidistant letter sequences

10. A boolean expression to truth table converter

11. A resolution theorem prover

12. An interpreter of a Prolog basic subset

13. A Markov Chain generator

14. An anagram generator

15. A library for doing computation inside various algebraic structures

16. A maze generator and solver

Some of these are exercises, some are toys, some look potentially useful. But except for the first two, they are all pure-functional problems, and are rather abstract. Maybe this sample isn't representative of all Haskell usage or what Haskell is capable of, but the stereotype, like most stereotypes, exists for a reason.

rkts··on Real World Haskell
You keep saying that, but I've never heard a justification for it that wasn't totally Kool-Aid flavored.

I'm all for safety in the sense of catching errors at compile time, provided they can be caught with minimal help from the programmer. Proof of more complicated properties should be optional. Haskell requires you to embed a proof of functional purity into every program you write, and this is just not how programming should work.

As to maintainability, this claim is clearly false. Pure programs become harder to change as they grow, because adding and removing side effects requires drastic restructuring.

Of course, most Haskell programs (in my limited observation) seem to deal with problems that are mostly mathematical or computational in nature, like compilers and Sudoku solvers, where these issues don't arise much. But that's not really an endorsement for something that purports to be useful in the Real World.

rkts··on Real World Haskell
Haskell has two useful features that are missing from the languages you mentioned:

1. Strong static typing

2. Pattern matching

(1) tends to make development go faster (in my experience) by catching your mistakes early and locating them more accurately than a debugger can. It's also good for performance.

(2) is great for any program that does a lot of stuff with trees, such as a compiler.

However, neither of these features is unique to Haskell. They're also present in OCaml, SML, F#, and Scala, all of which should be easier to learn and start using than Haskell.

The main qualities that distinguish Haskell from other languages are purity and laziness. These may be worth learning about since they're theoretically interesting, but their practical value is pretty dubious.

rkts··on First Person Plural
Summary: author defines a "self" as something with a fixed, consistent set of desires; observes that people have changing, inconsistent sets of desires; concludes that people are made of "many different selves." What an insight.
rkts··on First Person Plural
So that explains why conservatives have higher birth rates, live in low crime areas, oppose abortion and favor traditional family structures! Wait...
rkts··on Insecure Minds Wired for Pattern-Finding
cf. Hume, 1757

"In proportion as any man's course of life is governed by accident, we always find, that he encreases in superstition; as may particularly be observed of gamesters and sailors, who, though, of all mankind, the least capable of serious reflection, abound most in frivolous and superstitious apprehensions. The gods, says Coriolanus in Dionysius, have an influence in every affair; but above all, in war; where the event is so uncertain. ...

"Any of the human affections may lead us into the notion of invisible, intelligent power; hope as well as fear, gratitude as well as affliction: But if we examine our own hearts, or observe what passes around us, we shall find, that men are much oftener thrown on their knees by the melancholy than by the agreeable passions. Prosperity is easily received as our due, and few questions are asked concerning its cause or author. It begets cheerfulness and activity and alacrity and a lively enjoyment of every social and sensual pleasure: And during this state of mind, men have little leisure or inclination to think of the unknown invisible regions. On the other hand, every disastrous accident alarms us, and sets us on enquiries concerning the principles whence it arose: Apprehensions spring up with regard to futurity: And the mind, sunk into diffidence, terror, and melancholy, has recourse to every method of appeasing those secret intelligent powers, on whom our fortune is supposed entirely to depend."

rkts··on The Failure of Lisp? A Reply To Brandon Werner
How would you do this in Haskell? http://news.ycombinator.com/item?id=222189
rkts··on Usability Tip: Use Verbs as Labels on Buttons
The Mac dialog has a lot of text, yes, but it requires less reading to be understood, which, empirically, is what seems to matter most.

If you watch people use your software, one thing you notice right away is that many of them don't read ANY text. When a dialog shows up, they go straight to the buttons and click whichever one seems right--even if they don't know what the dialog is asking! It sounds crazy, but it's what people do.

rkts··on Usability Tip: Use Verbs as Labels on Buttons
The problem is that users typically read as little as is necessary to figure out what to do next--and very often, not even that much. Since the Windows dialog must be read entirely to be understood, it's more likely to be misinterpreted. E.g., a user may accidentally press "close," see the dialog, and think, "No, I didn't mean to close"... and then lose all their work.
rkts··on Are Big Name Universities Worth the Money?
Looks like yet another journalist who doesn't understand correlation vs. causation.
rkts··on Why English speakers dominate sprinting events
Someone ought to write a script that scans every submission for the words "startup," "Paul Graham," and "Y Combinator" and posts some variation of "Not Hacker News!!!!!" whenever it doesn't find them. At least it would save you all some effort.
rkts··on TwinLisp
Arc:

  (let (foo bar) nil ...)
rkts··on TwinLisp
You don't have to program directly in an AST to do metaprogramming. It's a trade-off: some people feel it's important to make metaprogramming as easy as possible, while others feel it's more important to have readable syntax.

Every Lisp dialect has some high-level syntax, e.g. quote, CL reader macros, and Arc ssyntax. These obscure the relationship between code and the underlying AST, but the designers felt that the gain in readability was worth it.

How much syntax should there be? A hard question, but I think it would be good for Lisp to move in the "more" direction. Readability is one of the big problems I have with Lisp, and macros, while certainly useful, make up only a small fraction of my code.

rkts··on Hippies, Nerds, and Lumpenprogrammers
The earlier versions were better, before esr fucked up the sections on politics and personality. Here's the first version in which that appendix appeared; search for "this profile".

http://jargon-file.org/archive/jargon-2.3.1.dos.txt

rkts··on What Makes Finnish Kids So Smart?
> it's mainly devoted to proving that African-Americans have lower IQs because of inferior genetics

No, it isn't.

rkts··on Hey language snobs: don't pinch pennies
If we were talking about purely functional languages, then I would agree. But Lisp isn't purely functional; it has assignment and loops and arrays and all the rest. You can program in the subset of Lisp that allows the same "mental model" as C and get the same results without worrying about pointers or buffer overflows. So I think Lisp is strictly easier.
rkts··on Hey language snobs: don't pinch pennies
C is more difficult than Lisp or OCaml, but it's extremely popular.
rkts··on Hey language snobs: don't pinch pennies
I wonder if personality has something to do with it. My guess is that language snobs are INTP, whereas Blub programmers are more INTJ. From the descriptions at http://www.personalitypage.com/portraits.html:

"INTPs value knowledge above all else. ... They hate to work on routine things - they would much prefer to build complex theoretical solutions, and leave the implementation of the system to others."

By contrast, "[an INTJ's] primary interest is not understanding a concept, but rather applying that concept in a useful way. Unlike the INTP, they do not follow an idea as far as they possibly can, seeking only to understand it fully. INTJs are driven to come to conclusions about ideas. Their need for closure and organization usually requires that they take some action."

Since INTPs are less motivated to action and "hate to work on routine things," they are driven to higher-level languages, because those languages help them focus on concepts instead of implementation details. But this means that the people using these languages get little done -- precisely because they are more interested in concepts than in implementation.

rkts··on On Math Teaching: Lockhart's Lament
I agree with this to some extent, but I think the author goes too far. The purpose of math education is not to make theoretical mathematicians. Only a small number of students in math classes will become mathematicians, and the rest are acquiring a set of tools that they'll use to solve problems in the real world. Proofs and conjectures and abstract reasoning, interesting as they may be, are irrelevant to most people's needs.

Here's a better analogy: a mathematician is a composer, and people who use math are singers and instrumentalists. There will always be a few people who love composing, and their work is important. But the majority of people have neither the ability nor the motivation to write original compositions. They'd rather just be given music to play.

For the composers among us, this can be hard to stomach. Writing music is so exhilarating, and playing is so mundane! How can anyone prefer the latter to the former? Well, the fact is, most people do. The rest of humanity really is different from us, and we need to accept that.

rkts··on In the Basement of the Ivory Tower
> the conclusions we come to about the world around us are the largest factor

Also known as "the blank slate theory." Or mostly-blank, if you want to be pedantic.

rkts··on In the Basement of the Ivory Tower
The funny thing about that quote is that it defeats itself.
rkts··on In the Basement of the Ivory Tower
Technically true, but sophist's experience is consistent with scientific findings. Sibling studies have repeatedly shown that genes do account for a significant amount of variation in behavior. While environment plays a role as well, the "blank slate" theory is flat wrong.

For an overview of the evidence, I recommend The Blank Slate by Steven Pinker.

rkts··on JL on Female Founders
http://en.wikipedia.org/wiki/Maternal_death

"The historical level of maternal deaths is probably around 1 in 100 births." However: "Mortality rates reached horrible proportions in maternity institutions in the 1800s, sometimes climbing to 40 percent of birthgiving women."

rkts··on Three Beautiful Quicksorts
It's also too inefficient to belong anywhere in the vicinity of working code.

Beautiful, elegant, useless. Maybe that should be the Haskell motto.

rkts··on Functional Programming Went Mainstream Years Ago
I agree. As with "OOP," the term "functional programming" is too broad to be the subject of a meaningful discussion about language design. It's better to break the term down into its sub-concepts, which are often independent of each other.

I question whether the notion of "programming paradigms" should exist. The more powerful a language is, the less I seem to notice paradigms in my code. I can't point to a piece of Lisp code and say, "this code is functional," or "this code is imperative," or whatever. I just use the tools that are most appropriate for what I'm trying to do.

Paradigms are like design patterns in this respect; they only seem to arise in languages whose weaknesses force you to write code a certain way. I think "multi-paradigm" languages like Lisp and OCaml would be better described as "no paradigm," and this is how languages ought to be.

rkts··on Why are geeks often atheist?
I'm not sure what your point is, but I think you're attacking a straw man. I didn't say that all people conform to the expectations of their peer group in all ways at all times. That statement is trivial to disprove.
rkts··on Why are geeks often atheist?
Geeks do not conform as much to the norms of society at large, but they do conform within their own groups. Conformity is a universal human trait.

Also, I don't see what your ad hominems contribute to this discussion.

rkts··on Why are geeks often atheist?
Isaac Newton was highly religious and he was smarter than any Digg user. In fact, most smart people in Newton's time were religious. Atheism in those days was associated with poor uneducated people, the same way racism is today. Doesn't that disprove the hypothesis that intelligence causes people to be atheist?

Wait, I know what you're going to say to that. You're going to say that Newton et al. don't count because they lived before Darwin. The theory of natural selection, you say, was the first non-religious explanation of life that smart people could believe. Before that, everyone just defaulted to religion because there was no better theory available.

It's a nice idea, but I don't buy it. When I became an atheist as a teenager, I wasn't thinking about evolution; I didn't even have the foggiest understanding of Darwin's theories. I've encountered many other atheists who don't. Obviously, evolution is not usually what causes people to reject religion.

I think the real difference is that, in Newton's time, it was fashionable for smart people to be religious, whereas in our time it's fashionable for smart people to be atheist. Evolution was just the fashion's tipping point.

Specifically, Darwin caused a few very smart people to change their minds about religion, and the greater bulk of somewhat smart people (who desperately wanted to seem like very smart people) followed suit. Now anyone who wants to be considered smart will reject religion out of conformance.

Basically, people will believe anything as long as their being wrong has no noticeable impact on their lives. Intelligence has little to do with it. And the moral of this story is not that you are all conformist sheep, but that it doesn't matter. If Isaac Newton struck out on the big questions, then you probably will too. Just stop trying to answer impossible questions, and go live your life.

rkts··on Campuses getting less political as '60s professors retire
Do you have any data to support that claim? The conservatives I know oppose gay marriage because they consider it immoral, not because of some abstract stuff about the democratic process.
rkts··on Campuses getting less political as '60s professors retire
Ok, but the point is, if you're willing to call people "crazy" because of their political opinions, I doubt that you're as committed to intellectual diversity as you claim to be.
← PreviousPage 2 of 4Next →