Live data from Hacker News

Try Clojure in your browser

tryclj.com

11–20 of 30 posts

Re: Try Clojure in your browser

#11
Nice to see this submission getting traction, especially given that the first submission got none at all. Clever of llambda to use the trailing question mark on the URL to confound PG's duplicate detection mechanism.

Re: Try Clojure in your browser

#13

Ummm.... Following the first thing in the tutorial: Clojure> (+3 3) java.lang.ClassCastException: java.lang.Long cannot be cast to clojure.lang.IFn http://gyazo.com/22c613f5bb4ebda5a36d0fbc0a85b83d What have I missed?

You need a space between the + and the first 3 (+ is the function you want to call).

Re: Try Clojure in your browser

#14

Ummm.... Following the first thing in the tutorial: Clojure> (+3 3) java.lang.ClassCastException: java.lang.Long cannot be cast to clojure.lang.IFn http://gyazo.com/22c613f5bb4ebda5a36d0fbc0a85b83d What have I missed?

You need a space between the + and the first 3 (+ is the function you want to call).

Thanks. The tutorial didn't show that:

http://gyazo.com/9d330e8bdb0537f9179c34ad2924928c

And when I click the tutorial's "(+3 3)" grey box, it inserts what looks like no space between the + and 3, and lo and behold, it works (6). And when I type it in now with no space (+3 3) it works too. :/

Re: Try Clojure in your browser

#15

Earlier quoted context omitted.

You need a space between the + and the first 3 (+ is the function you want to call).

Thanks. The tutorial didn't show that: http://gyazo.com/9d330e8bdb0537f9179c34ad2924928c And when I click the tutorial's "(+3 3)" grey box, it inserts what looks like no space between the + and 3, and lo and behold, it works (6). And when I type it in now with no space (+3 3) it works too. :/

oops - sorry - I'm totally misreading it. :/

Re: Try Clojure in your browser

#16
post #10

I have always been frustrated by tutorial REPLs that make me copy and paste example codes. I simply don't write them manually to CLI and I believe many people do so. Therefore maybe a link to directly paste and execute code on tutorial steps would be quite useful. Like "run this".

If you click some of the code examples in the tutorials, it will paste them into the REPL. You have to hit enter to run them though.

Re: Try Clojure in your browser

#20
post #8
post #2

I found it fun to see division results returned as fractions. Has anyone here switched from Python to Clojure for data analysis? What has been their experience?

Not recommended. Matrix multiplication is really slow, even with Incanter. I doubt you'll get very far with data analysis without multiplying a few matrices so avoid.

Slow compared to what? Numpy (or equivalent) or optimized fortran?
Post reply on HN