When this matters
Choose the smallest value shape that communicates the job: an atom for one fact, a proper list for sequential data, a vector for indexed mutable slots, or a bytevector for bounded bytes.
See it run
(list (vector? #(1 2)) (bytevector? #u8(1 2)) (pair? (cons 1 2)))Observed result
(#t #t #t)Read the example
The example asks three predicates about three different aggregate values. Each constructor creates the documented kind of value, so the result is a list of three true booleans.
How to reason about it
- Pairs, strings, and bytevectors are immutable in the current profile; vectors and lexical cells are mutable.
- Quoted aggregate data is immutable; constructors create runtime aggregates with the documented identity rules.
- Improper and cyclic structures are distinguished from proper lists; deep equality terminates on cycles.
Choose quickly
| Value family | Typical spelling | Mutation in the current profile |
|---|---|---|
| atoms | #t, 42, 2/3, name, #\\a | not applicable |
| list / pair | (list 1 2), (cons 1 2) | immutable |
| string | "hello" | immutable |
| vector | #(1 2) or (vector 1 2) | mutable slots |
| bytevector | #u8(1 2) | immutable |
| procedure | (lambda (x) x) | callable value; body is not data |
A common mistake
Complex numbers, ports, records, and mutable pairs or strings are outside the current profile.
Current boundaries
- Internal outcomes, signals, and uninitialized sentinels are not guest values.
Keep going
List and Aggregate Procedures gives constructors and accessors. Equality explains identity versus structural comparison.