Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Python problem. please help. thank you! Problem 2 (5 Points) Create a class called Circle that has the attributes center and radius. Make center a

image text in transcribed

Python problem. please help. thank you!

Problem 2 (5 Points) Create a class called Circle that has the attributes center and radius. Make center a Point object and radius a number (2 points). Instantiate a Circle object that represents a circle with a center at the point (100,125) and a radius of 50. Assign variables to all attribute values so they show up in the variable explorer (3 Points). Problem 3 (7 Points) Create a class called Triangle the has the attributes base, height and corner. Make corner a Point object and brse and height numbers (3 points). Instantiate a Triangle object that represents a triangle with a base of 4, height of 3 and the right (90) corner at (0,0). Assign variables to all attribute values so they show up in the variable explorer (4 points) Problem 4 (8 Points) Create a user defined function that uses the class Rectangle from THINK PYTHON and returns two point objects representing two corners needed to define the rectangle. Assume corner defines the location of the lower left corner (5 points). Instantiate a Rectangle object with a width of 150 a height of 250 and corner at the point test your function (50,-50) (3 points)

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

Database Publishing With Filemaker Pro On The Web

Authors: Maria Langer

1st Edition

0201696657, 978-0201696653

More Books

Students also viewed these Databases questions

Question

Distinguish between hearing and listening.

Answered: 1 week ago

Question

Use your voice effectively.

Answered: 1 week ago