#lang racket (define resume-test-3 #f) (define test-3 (lambda () ; the let defines a variable i local to the lambda, and ; sets its value to 0 (let ((i 0)) ; (call/cc (lambda (k) (set! resume-test-3 k))) ; ; The next time the-continuation is called, we start here. (displayln "I am back ") (set! i (+ i 1)) ; and return the value i i ) )) (test-3) (resume-test-3) (resume-test-3)