Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It's pretty much the same as this:

    (loop [n 0]
      (if (= n 10)
        n                 ; true case: return n
        (recur (inc n)))) ; false case: loop with n++

    ;=> 10


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: