Answered step by step
Verified Expert Solution
Question
1 Approved Answer
dr racket. i posted the first part of the question before this b then add a new blue shape with random size (SIZE) and random
dr racket. i posted the first part of the question before this
b then add a new blue shape with random size (SIZE) and random position where x is between 10.W) and y is between (0.H to the list-of-shapes & then add a new groen slupe with random size (SIZE) and candom position where x is between 0,W) and y is between (0.H to the list-of-shapes else do not add any shape and show list-of-shape itself 3. (25 points) Design mouse-f function which takes list-of-shapes, x, y and mouseEvent and produces a list-of-shapes on scene. The function checks the mouse event. If it is button-down, then add a new shape with random color (C), random size (SIZE) and random position where x is between 10,W) and 3 is between 10. to the list-of-shapes 4. (25 points) Design draw-f function which takes list-of-shapes and produces images on scene. The function draws shape using size, color and location of given shapes .constants size of the shape (define SIZE 25) width of the scene (define W 500) height of the scene (define H 500) max color range (define C 255) list-of-super > list-of-shapes (define main wo) (big-bang wo on-tick tick-1) (on-key key-1) (on-mouse mouse) (to-draw draw-f))) (define bl (make shape (random SIZE) (mako-color(random C)(ratudom Crandom C)) (make- posn (random W) (random H)))) (beline 12 (make-shape (random SIZE) (make-color (random Crandom C)(random C)) (male poon (random W) (random H)) (detine 13 (make shape (random SIZE) (male-color (random C)(random C)(randon C)) (male posn (random W) (random H)))) (define b4 (make-shape (random SIZE) (make color (random C)(random C)(random C)) (male poen (random W) (random H)))) (define 15 (make shape (random SIZE) (make-color (random C)(random C)(random C)) (make posn (random W) (random It)))) (define b6 (make shape (random SIZE) (make-color(random C) (random C)(random C)) (make pion (random W) (random HD)))) (define b7 (make shape (random SIZE) (make-color(random C)(random C)(random C)) (make posu (random W) (random H)))) (define bs (make-shape (random SIZE) (make-color (random C)(random C)(random C)) (malce posu (random W) (random H))) (deline 19 (make-shape (random SIZE) (make-color (raudem C)(random C)(random C)) (mnice posu (random W) (random H)))) (define b10 (make-shape (random SIZE) (make-color random Crandom C)(randomn C)) (make-posn (random W) (random H)))) (define los! (list b1 12 13 14 b5 b6 b7 58 9 610)) (main lol) b then add a new blue shape with random size (SIZE) and random position where x is between 10.W) and y is between (0.H to the list-of-shapes & then add a new groen slupe with random size (SIZE) and candom position where x is between 0,W) and y is between (0.H to the list-of-shapes else do not add any shape and show list-of-shape itself 3. (25 points) Design mouse-f function which takes list-of-shapes, x, y and mouseEvent and produces a list-of-shapes on scene. The function checks the mouse event. If it is button-down, then add a new shape with random color (C), random size (SIZE) and random position where x is between 10,W) and 3 is between 10. to the list-of-shapes 4. (25 points) Design draw-f function which takes list-of-shapes and produces images on scene. The function draws shape using size, color and location of given shapes .constants size of the shape (define SIZE 25) width of the scene (define W 500) height of the scene (define H 500) max color range (define C 255) list-of-super > list-of-shapes (define main wo) (big-bang wo on-tick tick-1) (on-key key-1) (on-mouse mouse) (to-draw draw-f))) (define bl (make shape (random SIZE) (mako-color(random C)(ratudom Crandom C)) (make- posn (random W) (random H)))) (beline 12 (make-shape (random SIZE) (make-color (random Crandom C)(random C)) (male poon (random W) (random H)) (detine 13 (make shape (random SIZE) (male-color (random C)(random C)(randon C)) (male posn (random W) (random H)))) (define b4 (make-shape (random SIZE) (make color (random C)(random C)(random C)) (male poen (random W) (random H)))) (define 15 (make shape (random SIZE) (make-color (random C)(random C)(random C)) (make posn (random W) (random It)))) (define b6 (make shape (random SIZE) (make-color(random C) (random C)(random C)) (make pion (random W) (random HD)))) (define b7 (make shape (random SIZE) (make-color(random C)(random C)(random C)) (make posu (random W) (random H)))) (define bs (make-shape (random SIZE) (make-color (random C)(random C)(random C)) (malce posu (random W) (random H))) (deline 19 (make-shape (random SIZE) (make-color (raudem C)(random C)(random C)) (mnice posu (random W) (random H)))) (define b10 (make-shape (random SIZE) (make-color random Crandom C)(randomn C)) (make-posn (random W) (random H)))) (define los! (list b1 12 13 14 b5 b6 b7 58 9 610)) (main lol) 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