forked from lspector/clojinc
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.txt
65 lines (55 loc) · 3.45 KB
/
README.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
The text below is the comment from the top of src/clojinc/core.clj.
When it refers to "this file" it is referring to that file.
;; clojinc
;; Steps toward clojure, starting from zero.
;; by Lee Spector <[email protected]>, 2011-2012
;; Version (date): 20120825
;; This file is a saved, re-executable Clojure REPL (Read Eval Print Loop)
;; session, with minimal comments and occasional problem sets. It is intended
;; to serve as the starting-point for semi-independent learning of the Clojure
;; programming language, for people who have at least some minimal experience
;; with at least one (any) programming language. No help is provided here for
;; getting a Clojure implementation/REPL up and running; consult the online
;; resources listed below, or search the web, if you need help with that.
;; The format of this file is alternating Clojure expressions with
;; commented-out output (including both the output produced by explicit print
;; statements and the values returned by the evaluated expressions). You should
;; be able to proceed through the file, evaluating an expression at a time, and
;; if you do this you should get the same output (or similar output, in cases
;; that involve nondeterminism). In many cases later expressions rely on having
;; evaluated earlier expressions in the file.
;; The material in this file is informal and idiosyncratic in its coverage,
;; leaving out many things that other Clojure introductions include and revealing
;; the Lisp-oriented bias of the author. The intention is just to lead beginners
;; deeply enough into Clojure territory for them to proceed in other directions
;; on their own.
;; More specifically, we begin with simple expressions for arithmetic and list
;; manipulation, introduce facilities for defining functions and macros, and give
;; progressively more complex examples of definitions that involve many of
;; Clojure's data structures including lists, vectors, maps, and sets. Among the
;; applications used for examples and problem sets are grammar-driven text
;; generation, genetic programming, and simple graphics. We also demonstrate
;; alternatives for defining iterative and recursive algorithms and briefly touch
;; upon topics ranging from debugging and profiling to file I/O and concurrency.
;; Many things are introduced here without explanation. My suggestion is that
;; you observe the output that is provided here, look things up in online resources
;; and in documentation that may be available in your Clojure environment, and,
;; most crucially, experiment with variations of the expressions presented here.
;; The problem sets are prods for further experimentation but it is best to
;; experiment continuously. Some of the problems provided here are easy, some are
;; quite hard, and many could be completed/varied/extended in several different
;; ways.
;; Potentially useful online resources include:
;; http://clojure.org
;; http://dev.clojure.org/display/doc/Getting+Started
;; http://groups.google.com/group/clojure
;; http://4clojure.com
;; http://clojuredocs.org
;; http://www.clojure-toolbox.com
;; http://www.clojureatlas.com
;; http://alexott.net/en/clojure/video.html
;; http://planet.clojure.in/
;; Most of the outputs in clojinc were created using clojure version 1.3 in a
;; REPL started with Leiningen 1.7.1 (https://github.com/technomancy/leiningen)
;; and using Java 1.6.0_33. (A few were left from an earlier version, for which
;; Clooj (https://github.com/arthuredelstein/clooj) was used.