1a Beginning Student Language
Questions
What does Racket ultimately evaluate an expression into?
Multiple choice
Which expression correctly follows Racket prefix notation?
Multiple choice
What does (substring "012345" 2 4) produce?
Multiple choice
Which library is required for primitives such as rectangle and image-width?
Multiple choice
What does the text primitive produce?
Multiple choice
What happens when Racket evaluates a constant name such as WIDTH?
Multiple choice
What is a predicate?
Multiple choice
How does an if expression evaluate its branches?
Multiple choice
What happens when evaluating (and false (/ 1 0))?
Multiple choice
Which statement about or is correct?
Multiple choice
Why are parameters useful in a function?
Multiple choice
In a function call, what normally happens before parameter values are substituted into the body?
Multiple choice
What is the best description of overlay compared with above?
Multiple choice
What is a good use of the DrRacket Stepper?
Multiple choice
If you know the primitive beside and want a related image-layout primitive, what strategy from the notes is appropriate?
Multiple choice
What value does (substring "012345" 2 4) evaluate to? Briefly explain which character positions are included.
Short answer
What kind of value does (text "Hello" 20 "red") produce: a String, Number, Boolean, or Image?
Short answer
Write a Racket expression using and that returns false when x is 0 without attempting to evaluate (/ 10 x), and otherwise checks whether (/ 10 x) is greater than 2.
Short answer
Write a Racket expression in prefix notation that calculates 3 + (4 * 2).
Short answer
Write a Racket function named larger-than-10? that consumes a number n and produces true when n is greater than 10 and false otherwise.
Short answer