From 59bfb9c3fd1b3f3639b0c13ea899c2c42b67bb71 Mon Sep 17 00:00:00 2001 From: Ramakrishnan Muthukrishnan <vu3rdd@gmail.com> Date: Sun, 11 Dec 2011 00:32:37 +0530 Subject: [PATCH] solution to 4.15 --- src/sicp/ex4_15.rkt | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100644 src/sicp/ex4_15.rkt diff --git a/src/sicp/ex4_15.rkt b/src/sicp/ex4_15.rkt new file mode 100644 index 0000000..689a1c9 --- /dev/null +++ b/src/sicp/ex4_15.rkt @@ -0,0 +1,16 @@ +#lang racket + +(define (run-forever) + (run-forever)) + +(define (try p) + (if (halts? p p) + (run-forever) + 'halted)) + +#| + +Now, if you run (try try) then, we check if (try try) would halt. If it halts, then we run forever, else we return. +This is contradictory to the assumption. + +|# \ No newline at end of file -- 2.45.2