Permalink
Browse files

ch3

  • Loading branch information...
1 parent 3eba47e commit 399c3c48d1099a23d361b36f02484b62511cd85d @flaming0 committed Aug 14, 2012
Showing with 10 additions and 0 deletions.
  1. +10 −0 ch3/test_concurrency.scm
@@ -0,0 +1,10 @@
+;; In order to use `parallel-execute' you need this:
+;; http://planet.racket-lang.org/display.ss?package=sicp-concurrency.plt&owner=dyoo
+;; install package, reboot drracket, change language to "SICP Concurrency language"
+
+(define x 10)
+
+(parallel-execute (lambda () (set! x (* x x)))
+ (lambda () (set! x (+ x 1))))
+
+x

0 comments on commit 399c3c4

Please sign in to comment.