Answered step by step
Verified Expert Solution
Question
1 Approved Answer
in python: Create a Line class using the class skeleton below. Fill in the code needed for each function. (Hint: coor1, coor2 are tuples) class
in python:
Create a Line class using the class skeleton below. Fill in the code needed for each function. (Hint: coor1, coor2 are tuples) class Line: def __init__(self, coor1, coor2): pass def distance(self): pass def slope(self): pass
Sample output: coordinate1 = (3,2) coordinate2 = (8,10) li = Line(coordinate1, coordinate2) print(li.distance()) 9.433981132056603 print(li.slope()) 1.6
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