Hello,
I am very excited about opportunities of what I can do in Clojure. I am
a long time Squeaker (Smalltalk), and also Python user, dabbling at
times in various other languages. I have briefly explored Scala as an
option for my business app. But, I really am a dynamic typing guy. :)
I have in general not learned Lisp previously because I was spoiled by
the environment in Squeak which is not found, in general, outside of
Smalltalk. However, I am writing a business application which requires
using Java libraries. Hence my search for a JVM language which makes
using Java less painful and more productive. I have great hope for
Clojure being that language. It being a Lisp is a big win to me. The
power of Lisp is known, even among those who don't use it. I absolutely
love the fact that Rich explicitly wants a practical Lisp that is
available for writing business apps on the platform chosen for many
business apps. That hits me where I live.
I am working my way through the Programming Clojure book. I really want
to get Clojure in my head and get productive with it.
On page 67 is-small? is defined as:
(defn is-small? [number]
(if (< number 100) "yes" "no" ))
Is is-small? a predicate? If so, is this a common pattern for such
predicates?
The reason I ask, is because on page 52 a predicate is defined as:
A predicate is a function that returns either true or false. In
Clojure, it is
idiomatic to name predicates with a trailing question mark, for example
true?, false?, nil?, and zero?:
If this is strictly true, then is-small? is not a predicate as it
returns values other than true or false. And as such could not be used
in a situation which required such.
Just attempting to clarify my understanding, so that I proceed
correctly, with proper understanding.
Thanks for any wisdom, understanding and guidance in my journey to Clojure.
Jimmie
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---