In one case of my cond
, I need to do multiple procedures then return a value at the end. However, my current implementation gives me an error:
application: not a procedure;
expected a procedure that can be applied to arguments
(cond
[(string? expr) expr]
[(number? expr) expr]
[(list? expr) (begin
(hash-set! my-table (car expr) (cdr expr))
("hi") ; I want to return this
)
]
)
Can anybody help me understand how I'd have multiple lines in a cond
?