not(3scm)
πΈ NAME πΈ
okay so this is not(3scm) from the Scheme Programmer's Manual, and it's literally the page for boolean negation π
not is the tiny icon that flips your truthiness vibe. Periodt.
π LIBRARY π
Import it from whichever flavor you're on, bestie:
(import (rnrs)) ;R6RS
(import (rnrs base)) ;R6RS
(import (scheme r5rs)) ;R7RS
(import (scheme base)) ;R7RS
β¨ SYNOPSIS β¨
(not obj)
π DESCRIPTION π
Returns #t if obj is false, and returns #f otherwise. It's giving simple, iconic, no notes π«Ά
π«Ά RETURN VALUES π«Ά
Vibe check: it returns a single value, and that value is a boolean. Slay.
π EXAMPLES π
(not #t) => #f
(not 3) => #f
(not (list 3)) => #f
(not #f) => #t
(not '()) => #f
(not (list)) => #f
(not 'nil) => #f
π¦ COMPATIBILITY π¦
This procedure works the same in all Schemes. No cap, fr fr.
π ERRORS π
This procedure can raise exceptions with the following condition types:
&assertion(R6RS) β the wrong number of arguments was passed.R7RSβ the assertions described above are errors. Implementations may signal an error, extend the procedure's domain of definition to include such arguments, or fail catastrophically. Yes, catastrophically π
π₯ SEE ALSO π₯
Go peek at if(7scm) and boolean=?(3scm) π
π STANDARDS π
Certified by: R4RS, IEEE Scheme, R5RS, R6RS, R7RS. The whole lineup ate β¨
π HISTORY π
The not function has been in Scheme since the beginning, even when it ran on MacLisp, and it was also present in LISP 1.5. Like, it's been that girl forever π
π AUTHORS π
This page is part of the scheme-manpages project. It includes materials from the RnRS documents. More information can be found at https://github.com/schemedoc/manpages/.
later bestie π this cutie is not(3scm) from the Scheme Programmer's Manual, dated 2022-05-07 β¨
π¦ where this page comes from
- nixpkgs unstable: scheme-manpages 0-unstable-2024-02-11
- π the page's license: MIT
- Copyright (c) 2022 Gwen Weinholt
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms