Question
dr racket :I want to replace x & y functions with posn (define UFO (underlay/align center center (underlay/offset (circle 10 solid gray) 0 -10 (underlay/offset
dr racket :I want to replace x & y functions with posn
(define UFO (underlay/align "center" "center" (underlay/offset (circle 10 "solid" "gray") 0 -10 (underlay/offset (rectangle 10 8 "solid" "white") -30 0 (rectangle 10 8 "solid" "white"))) (rectangle 40 8 "solid" "white"))) rectangular line (check-expect (real-x->screen-x -1) 0) (check-expect (real-x->screen-x 0) 250) (check-expect (real-x->screen-x 1) 500) (define (real-x->screen-x real-x) (+ (* real-x 250) 250)) (check-expect (real-y->screen-y 1) 0) (check-expect (real-y->screen-y 0) 250) (check-expect (real-y->screen-y -1) 500) (define (real-y->screen-y real-y) (- 500 (+ (* real-y 250) 250))) (define curve 50) (define (x t) (cos (/ t curve))) (define (y t) (sin (/ t curve))) (define (create-UFO-scene t) (underlay/xy background (real-x->screen-x (x t)) (real-y->screen-y (y t)) UFO))
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started