Problem 04 (40 points) 1
(10 points) Create a custom class called animal which only contains the method _init_ used to initialize three data attributes:
1) the animal's name,
2) its position along x coordinate, 3) its position along y coordinate
2 (10 points) Create a custom class dog inherited from the class animal, and define a method called distance which calculates the distance between the position of the dog and another object in a (x,y) coordinate system
3 (5 points) Create an instance of the class dog, give your dog a name, position your dog at location (0,0) in the (x,y) coordinate system. Create an instance of the class animal, give this animal the name danger, and position this animal at location (0.2,0.2). Invoke the method distance to calculate the distance between your dog and danger, then print this distance.
4 (10 points) Create an empty list named trajectory. Using a while loop, increment the x coordinate location of your dog by 0.1 at each step, recalculate the distance between your dog and danger, append this distance to the list trajectory, and exit the loop when this distance is larger than 0.8 units. Write the list in a file called Dog2D.txt 5 (5 points) Everything is an object in Python. A list is an object. In 4.4, you instantiated a list called trajectory. Invoke a built-in Python function on this list object to calculate the smallest distance your dog was to the danger in the trajectory followed, then print this distance.
CS 340 Milestone One Guidelines and Rubric Overview: For this assignment, you will implement the fundamental operations of create, read, update,
Retail Transaction Programming Project Project Requirements: Develop a program to emulate a purchase transaction at a retail store. This
7COM1028 Secure Systems Programming Referral Coursework: Secure
Create a GUI program that:Accepts the following from a user:Item NameItem QuantityItem PriceAllows the user to create a file to store the sales receip
CS 340 Final Project Guidelines and Rubric Overview The final project will encompass developing a web service using a software stack and impleme