aboutsummaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
Diffstat (limited to 'README.md')
-rw-r--r--README.md50
1 files changed, 20 insertions, 30 deletions
diff --git a/README.md b/README.md
index 0ba7922..02b9116 100644
--- a/README.md
+++ b/README.md
@@ -1,39 +1,29 @@
-# pict-sexp
-Draw sexp.
+# pict-cons
+Draw cons.
-![fib.png](https://raw.githubusercontent.com/wiki/tojoqk/pict-sexp/images/fib.png)
+![example1.png](https://files.tojo.tokyo/pict-cons/example1.png)
# INSTALL
-```
-raco pkg install https://github.com/tojoqk/pict-sexp.git
-```
+
+ raco pkg install https://github.com/tojoqk/pict-cons.git
# UPDATE
-```
-raco pkg update https://github.com/tojoqk/pict-sexp.git
-````
+
+ raco pkg update https://github.com/tojoqk/pict-cons.git
# UNINSTALL
-```
-raco pkg remove pict-sexp
-```
+
+ raco pkg remove pict-cons
# USAGE
-Save as "pict-fib.png".
-```
-#lang racket
-(require pict)
-(require pict-sexp)
-
-(define pict-fib
- (pict-sexp
- '(define (fib n)
- (cond
- [(= n 0) 0]
- [(= n 1) 1]
- [else
- (+ (fib (- n 1))
- (fib (- n 2)))]))))
-
-(send (pict->bitmap pict-fib) save-file "pict-fib.png" 'png)
-```
+
+Save as "pict-example.png".
+
+ #lang racket
+ (require pict)
+ (require pict-cons)
+
+ (define pict-example
+ (pict-cons '(+ a (* b c))))
+
+ (send (pict->bitmap pict-example) save-file "pict-example.png" 'png)