1. Create a Graph Win frame with title Rectangle Area, Perimeter and Diagonal and size 320...
Fantastic news! We've Found the answer you've been seeking!
Question:
Transcribed Image Text:
1. Create a Graph Win frame with title Rectangle Area, Perimeter and Diagonal and size 320 by 240 pixels. 2. Set the coordinates of the graphical frame to be (0,0) in the lower left corner and (10,10) in the upper right corner. 3. Create two Point objects and a Rectangle object from these two points so that the rectangle has size 3 by 4. 4. Display the rectangle using your choice of a fill and an outline color (either use colors mentioned in the chapter or search online for X11 color names). 5. Compute and display the width, length, perimeter, area and the diagonal length of the rectangle. These values must be shown in the graphical window. Turn in your Python script (the .py file) and a screenshot that shows a test of your program. 1. Create a Graph Win frame with title Rectangle Area, Perimeter and Diagonal and size 320 by 240 pixels. 2. Set the coordinates of the graphical frame to be (0,0) in the lower left corner and (10,10) in the upper right corner. 3. Create two Point objects and a Rectangle object from these two points so that the rectangle has size 3 by 4. 4. Display the rectangle using your choice of a fill and an outline color (either use colors mentioned in the chapter or search online for X11 color names). 5. Compute and display the width, length, perimeter, area and the diagonal length of the rectangle. These values must be shown in the graphical window. Turn in your Python script (the .py file) and a screenshot that shows a test of your program.
Expert Answer:
Answer rating: 100% (QA)
Heres a Python script that implements the steps you mentioned using the graphics module in Python py... View the full answer
Related Book For
Using Microsoft Excel and Access 2016 for Accounting
ISBN: 978-1337109048
5th edition
Authors: Glenn Owen
Posted Date:
Students also viewed these programming questions
-
Suppose and based on the publication of the Ministry of Health, Pizza is considered a harmful item and causes overweight problems, and this leads to consumption reduction. Explain graphically the...
-
Planning is one of the most important management functions in any business. A front office managers first step in planning should involve determine the departments goals. Planning also includes...
-
In this assignment, you will create a program that allows theuser to draw in a window using brushes of different sizes andcolors. The user will be able to change the size and color of thebrush using...
-
Greety Food in Ashland, Kentucky, manufactures and markets snack foods. Sita Lee manages the company's fleet of 220 delivery trucks. Lee has been charged with *reengineering* the fleet-management...
-
What is the effect on the deposit expansion process if banks choose to hold more excess reserves? Why might they do so?
-
Consider the UML diagram used to model Steves Stylin Sunglasses (SSS) sales data. Draw a new UML diagram assuming that SSS sells mass-produced brand-name sunglasses instead of custom sunglasses?
-
The following data is available for a four stroke petrol engine stroke volume \(=6\) Litres. Mean effective pressure \(=6\) bar. Speed of engine \(=750\) RPM. Calculate i.p. of the engine.
-
Figure 4-37 includes an EER diagram describing a publisher specializing in large edited works. Transform the diagram into a relational schema that shows referential integrity constraints (see Figure...
-
Using loop logic in a python code snippet, create a loop that counts down from 15 to 5 by 5's printing the count as it is processing. example output: Counter Example count 15 count 10 count 5
-
Oasis Co., a U.S. shareholder, owns 100% of Shack Co. and 100% of Studio Co., both CFCs. Shack Co. has $300,000 of gross income, of which $50,000 is effectively connected income, and $30,000 is...
-
Wiset Company completes these transactions during April of the current year (the terms of all its credit sales are 2/10, n/30). Apr. 2 Purchased $14,300 of merchandise on credit from Noth Company,...
-
List and briefly describe the principal causes of high population growth in developing countries and the major consequences.
-
What are the possibilities, advantages, and disadvantages of export promotion in developing nations with reference to specific types of commodities (e.g., primary food products, raw materials, fuels,...
-
What is meant by the statement that many developing nations are subject to dominance, dependence, and vulnerability in their relations with rich nations? Can you give some examples?
-
If land reform is efficient, why do you think it is not more commonly implemented?
-
Why should any analysis of development problems place heavy emphasis on the study of agricultural systems, especially peasant agriculture, and the rural sector?
-
Therap software company is trying to establish its optimal capital structure. The companys current capital structure consists of 35% debt and 65% equity; however, the treasurer believes that the firm...
-
If a test has high reliability. O the test measures what the authors of the test claim it measures O people who take the same test twice get approximately the same scores both times O scores on the...
-
What view of a form is used to edit an existing form?
-
Describe how to create a trend line for a chart.
-
Create a new What SUP Cost Analysis a. Using the ch7-02 file to start your work, create a worksheet to do the following: i. Calculate the Hi-Lo Method variable cost/hour open and fixed cost. ii....
-
The control volume shown in Figure \(P 2.15\) has steady, incompressible flow, and all properties are uniform at the inlet and outlet. For \(u_{1}=1.256 \mathrm{MJ} / \mathrm{kg}\) and...
-
(a) List the forces exerted on the spring-cart system of Figure 15.1 right after it is released, and draw a freebody diagram for each object in the system. (b) Which of these forces do work on the...
-
(a) In Figure 15.2e, the cart's displacement from the equilibrium position is maximum. Is the \(x\) component of the cart's acceleration at that instant positive, negative, or zero? (b) At which...
Study smarter with the SolutionInn App