What about a golf competition on the golf competition scorer? Then we
can evaluate that using;
(defmacro score-scorer [scorer] ... )
:)
- Adrian
On Thu, Sep 10, 2009 at 8:12 AM, Christophe Grand wrote:
>
> I propose to compute the score of a golf competition entry using this
> function:
> (d
srolls and Laurent,
Thanks for your replies. I still can't figure it out and I'm
switching to eclipse.
On Sep 10, 12:45 am, srolls wrote:
> I have had similar issues with swing. Going to the inferior lisp buffer and
> hitting return once or twice always resolved it. It only happens the first
>
2009/9/10 Phil Hagelberg :
>
> Rick Moynihan writes:
>> This issue has got me thinking that the real problem appears to be
>> that there isn't a standard or default way (script) to start up and
>> run java/clojure projects... i.e. though this solves the problem when
>> running clojure programs in
Hi,
On Sep 10, 3:52 pm, MarkSwanson wrote:
> Just for fun I actually tried this:
>
> Clojure=> (time (lpf6b 1234567890123456789012345678901234567890))
> The prime factorization of 1234567890123456789012345678901234567890
> is :5964848081
> "Elapsed time: 5519.278432 msecs"
>
> I can't confirm th
> Just thought you would like to know that Wolfram|Alpha agrees (in
> roughly the same time):
>
> http://www.wolframalpha.com/input/?i=factor+1234567890123456789012345...
Thanks!
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Goo
I still use clojure-mode and it's basic LISP interaction features.
I've installed SLIME once and went through the hassle of getting it
working, but it didn't (seem) to offer much more. It also made
quitting an infinite loop difficult (C-c C-c didn't work for me in
SLIME). So eventually i just move
On Wed, Sep 9, 2009 at 00:16, Richard Newman wrote:
>
>> So, my question is this: is there a way to print a structure out in
>> a fashion that it can be read back in correctly (i.e. with strings
>> being quoted), and without having to write my own print function?
>
> prn.
>
> user=> (prn {:foo ["
2009/9/9 Brian Hurt :
[...]
> So, my question is this: is there a way to print a structure out in a
> fashion that it can be read back in correctly (i.e. with strings being
> quoted), and without having to write my own print function?
To go along with the other answers, you will want to bind *rea
Hello. I'm trying to use (class String) to get the class object for
the String class. However, nomatter what class typ ei pass, i always
get java.lang.Class back. Is this the way its supposed to work?
Thx!
--~--~-~--~~~---~--~~
You received this message because yo
You need to pass the object to (class, e.g...
user=> (class "a")
java.lang.String
user=> (class String)
java.lang.Class
user=> (class 1)
java.lang.Integer
(So String is actually a Class object).
Rgds, Adrian.
On Thu, Sep 10, 2009 at 5:00 PM, Gorsal wrote:
>
> Hello. I'm trying to use (class St
Yes.
(class "an instance of Stirng") will return java.lang.String
Now the clojure symbol String is bound to a java.lang.Class instance giving
information on the java.lang.String class (as if you had issued
"kljlkjk".getClass()).
2009/9/10 Gorsal
>
> Hello. I'm trying to use (class String) to ge
What you're getting is the class of the String class, which is Class.
What you want is just plain "String".
On Thu, Sep 10, 2009 at 11:00 AM, Gorsal wrote:
>
> Hello. I'm trying to use (class String) to get the class object for
> the String class. However, nomatter what class typ ei pass, i alw
Hello,
I am looking to write a SOAP client in Clojure and was wondering if
there are any good existing libraries/clients in Java. After a bit of
searching i came across Apache Axis and JAX-WS, though i am not sure
how useful they will be and JAX-WS uses annotations.
Has anyone had any experience
2009/9/9 Phil Hagelberg :
>
> The solution I've settled on is the clojure-project function:
>
> (defun clojure-project (path)
> "Setup classpaths for a clojure project and starts a new SLIME session.
> Kills existing SLIME session, if any."
> (interactive (list
>
Ah. So class returns the class of the instance, and does not find the class
with the name given. So , if I wanted to get the class of a ExecutionEvent,
I would
Have to go (Class/forName "org.eclipse.core.commands.ExecutionEvent")?
Preferrably, I would like to simply go (Class/forName "ExecutionE
On Thu, Sep 10, 2009 at 1:20 PM, Seth Burleigh wrote:
> Ah. So class returns the class of the instance, and does not find the
> class with the name given.
>
Yes.
> So , if I wanted to get the class of a ExecutionEvent, I would
>
> Have to go (Class/forName "org.eclipse.core.commands.ExecutionEv
I've been working on a project (both client and server) for the last
few weeks using Clojure and SOAP.
I looked around for anything SOAP related and didn't find much. I
ended up just using the Apache Axis library. Their WSDL2Java saved me
quite a bit of time. Right now I have more java code than
Hi,
I'd like to know whether there is already something in clojure.contrib
that installs a method with multiple dispatch-values, i.e. given a
multimethod like:
(defmulti some-multi identity)
instead of installing several methods with different dispatch values
that do the same thing:
(defmethod
> (hypothetic-defmethods some-multi [:a :b] [arg] (do-something))
Multimethods are dispatched using isa?.
The idiomatic Clojure way of doing what you want is to define *one*
method against something higher up in the hierarchy than both :a and :b.
For example, if your two values are ::get and
> The idiomatic Clojure way of doing what you want is to define *one*
> method against something higher up in the hierarchy than both :a and :b.
>
> For example, if your two values are ::get and ::head, perhaps you
> should be defining a handler for ::idempotent-http-method.
Thanks; fits perf
http://github.com/rnewman/clj-conneg/tree/master
This is now pretty much finished, apart from more detailed sorting.
E.g., you can ask:
(conneg/best-allowed-content-type
"image/*; q=0.9, text/html; q=0.1, text/plain; q=0.8"
#{"image/jpeg"})
=>
("image" "jpeg")
i.e., it co
I wrote a Kate script to make lisp development on Kate a little more
pleasant.
It was written primarily with Clojure in mind, so it should work best
with this language, but it's pretty generic.
If you use Kate, please try it and feel free to add a comment to the
kde bug report (see below).
You c
Tom Faulhaber writes:
> Also, one thing that I (and others) have noticed is that clojure mode
> chokes on the #^{} form metadata on namespaces. (See any of the files
> in clojure-contrib for an example.) I'm not able to reproduce the
> problem now, so if you don't already know what it is, I'll k
I'd like to second all of this. The very first time I had to fix
someone else's bug was when the dev used "a.compareTo(b) == -1".
On Sep 9, 1:37 am, B Smith-Mannschott wrote:
> On Tue, Sep 8, 2009 at 23:35, Stephen C. Gilardi wrote:
>
> > On Sep 8, 2009, at 2:14 AM, Timothy Pratley wrote:
>
>
uau cutting the Gordian knot
On 8 sep, 05:39, Timothy Pratley wrote:
> Yet another way :)
>
> user=> (map + (rest a) a)
> (3 5 7 9 11)
--~--~-~--~~~---~--~~
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this
25 matches
Mail list logo