Make a class for drawing a car. A two-dimensional car can be drawn by putting together a rectangle, circles, arcs, and lines. Make a class in the Shape hierarchy from Chapter 9.4 for drawing a car, following the same principle as in Exercise 9.20. The constructor takes a length L of the car and the coordinates of a point p. The various shapes that build up the car must have dimensions relative to L and placements relative to p. Draw a small car and a large car in the same figure. Name of program file: draw_car.py.
Already registered? Login
Not Account? Sign up
Enter your email address to reset your password
Back to Login? Click here