Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Use Python 3 or above Our sun appears bright in the daytime sky most of the time. During a solar eclipse however, the moon passes

image text in transcribed

Use Python 3 or above

Our sun appears bright in the daytime sky most of the time. During a solar eclipse however, the moon passes between the earth and sun casting a shadow on the surface of the earth. You have been asked to create a animated graphics simulation of the appearance of a solar eclipse from the earth's surface. Define a function named q30 that uses the Python Graphics module and creates a 300x300 window with a black background. A large white circle (radius 100) should be drawn in the center of the graphics window and will represent the sun. A text message should appear in the middle of the circle asking the user to click to begin the simulation. Once a mouse click is detected, the message should be removed and an identically sized black circle representing the moon should start to the left of the 'sun' then pass from left-to-right smoothly across until it eventually blocks our view of the sun. The moon's black circle should continue to move across the screen (1 or 2 pixels at a time) until the sun is completely visible again. At this point another message should appear stating the the simulation is over. A final mouse click should close the graphics window and the function should end Your function should create a graphics animation very similar to the following screenshots: The q30 function will not accept any parameters or return any values. All the necessary commands for the graphics animation should be contained within the function

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle9i Database Administrator Implementation And Administration

Authors: Carol McCullough-Dieter

1st Edition

0619159006, 978-0619159009

More Books

Students also viewed these Databases questions

Question

a. Do team members trust each other?

Answered: 1 week ago

Question

How do members envision the ideal team?

Answered: 1 week ago

Question

Has the team been empowered to prioritize the issues?

Answered: 1 week ago