17,716
questions
676
votes
6
answers
180k
views
Scala vs. Groovy vs. Clojure [closed]
Can someone please explain the major differences between Scala, Groovy and Clojure. I know each of these compiles to run on the JVM but I'd like a simple comparison between them.
298
votes
1
answer
18k
views
How can I make nrepl-ritz-jack-in work remotely over TRAMP / Emacs
What I want:
I have a clojure program on a remote site, let's call it mccarthy.
What I want to do is connect to a nrepl-ritz from my laptop, preferably using nrepl-ritz-jack-in. The jack in works ...
235
votes
14
answers
49k
views
Debugging in Clojure? [closed]
What are best ways to Debug Clojure code, while using the repl?
219
votes
16
answers
56k
views
How do you make a web application in Clojure? [closed]
I suppose this is a strange question to the huge majority of programmers that work daily with Java. I don't. I know Java-the-language, because I worked on Java projects, but not Java-the-world. I ...
205
votes
13
answers
24k
views
Is there a software-engineering methodology for functional programming? [closed]
Software Engineering as it is taught today is entirely focused on object-oriented programming and the 'natural' object-oriented view of the world. There is a detailed methodology that describes how to ...
197
votes
19
answers
102k
views
Test whether a list contains a specific value in Clojure
What is the best way to test whether a list contains a given value in Clojure?
In particular, the behaviour of contains? is currently confusing me:
(contains? '(100 101 102) 101) => false
I ...
193
votes
8
answers
80k
views
How to reload a clojure file in REPL
What is the preferred way of reloading functions defined in a Clojure file without having to restart the REPL. Right now, in order to use the updated file I have to:
edit src/foo/bar.clj
close the ...
180
votes
6
answers
81k
views
In Clojure 1.3, How to read and write a file
I'd like to know the "recommended" way of reading and writing a file in clojure 1.3 .
How to read the whole file
How to read a file line by line
How to write a new file
How to add a line to an ...
176
votes
10
answers
52k
views
Calling clojure from java
Most of the top google hits for "calling clojure from java" are outdated and recommend using clojure.lang.RT to compile the source code. Could you help with a clear explanation of how to call Clojure ...
173
votes
5
answers
32k
views
In Clojure, when should I use a vector over a list, and the other way around?
I read that Vectors are not seqs, but Lists are. I'm not sure what the rationale is for using one over the other. It seems that vectors are used the most, but is there a reason for that?
161
votes
4
answers
38k
views
difference between use and require
Can anyone explain the difference between use and require, both when used directly and as :use and :require in the ns macro?
155
votes
17
answers
50k
views
What is the best way to do GUIs in Clojure?
What is the best way to do GUIs in Clojure?
Is there an example of some functional Swing or SWT wrapper?
Or some integration with JavaFX declarative GUI description which could be easily wrapped to s-...
154
votes
2
answers
21k
views
Simple explanation of clojure protocols
I'm trying to understand clojure protocols and what problem they are supposed to solve. Does anyone have a clear explanation of the whats and whys of clojure protocols?
151
votes
12
answers
63k
views
Mapping a function on the values of a map in Clojure
I want to transform one map of values to another map with the same keys but with a function applied to the values. I would think there was a function for doing this in the clojure api, but I have been ...
150
votes
4
answers
32k
views
Please explain some of Paul Graham's points on Lisp [closed]
I need some help understanding some of the points from Paul Graham’s What Made Lisp Different.
A new concept of variables. In Lisp, all variables are effectively pointers. Values are what have types, ...