Skip to content

Boolean

Given a file named “main.scm” with:

(import (scheme base))
(write-u8 (if (boolean? <value>) 65 66))

When I successfully run stak main.scm

Then the stdout should contain exactly “<output>”.

value output
#f A
#t A
’() B

Given a file named “main.scm” with:

(import (scheme base))
(write-u8 (if (not <value>) 65 66))

When I successfully run stak main.scm

Then the stdout should contain exactly “<output>”.

value output
#f A
#t B

Given a file named “main.scm” with:

(import (scheme base))
(write-u8 (if (boolean=? <values>) 65 66))

When I successfully run stak main.scm

Then the stdout should contain exactly “<output>”.

values output
#f #f A
#f #t B
#t #f B
#t #t A
#f #f #f A
#t #t #t A
#f #f #t B
#t #t #f B