writing a C++ code, its a beginner level code. Design a class house that defines a house on a street. A house has a house number and an (x,y) location, where x and y are numbers between -10 and 10. the key member is plot, which the plot the house, next design a class street that contains a number of equally spaced house. An object of type street stores the first house, the last house (which can be anywhere on the screen), and the number of houses on the street. The street :: plot function needs to make the intermediate house objects on the fly, because you dont yet know how to store an arbitrary number of objects. use these classes in a graphics program in which the user clicks with the mouse on the locations of the first and last house, then enters the house number of the first and last house, and the number of houses on the street. Then the entire street is plotted Each house has a chimney and produces smoke randomly as in the graphics intro handout. Implemented in an inteligent way.

Designing a class in C++ to represent a house on a street requires careful consideration of the underlying structure and properties associated with the house and street. In this assignment, we will develop two classes: “House” and “Street” to encapsulate the relevant information and functionality.

Let’s begin by defining the “House” class. Each house on the street is characterized by a house number, represented by a natural number, and a location specified by Cartesian coordinates (x, y), where x and y are floating-point numbers within the range of -10 to 10. Additionally, the most important property of a house is its plot, which will be used to represent the visual representation of the house.

Next, we will design the “Street” class that contains a number of equally spaced houses. An object of this class will store the information of the first house, last house, and the total number of houses on the street. To plot the entire street, the “Street::plot” function will dynamically create intermediate house objects.

To implement the “House” class, we will define the necessary data members and member functions. The data members will include the house number and the (x, y) location of the house. The member functions will consist of a constructor that initializes the house with the given number, coordinates, and randomly assigns the presence of a chimney. Additionally, a function to produce smoke randomly can be implemented.

The “Street” class will include data members such as the first house, the last house, and the total number of houses on the street. The member functions will consist of a constructor that takes the initial and final house coordinates along with the number of houses as input. Within this constructor, intermediate house objects will be created dynamically. Additionally, a “plot” function can be implemented to visually represent the entire street.

In the graphical program, the user will be required to click with the mouse to specify the locations of the first and last houses, enter the house numbers for these houses, and provide the total number of houses on the street. The program will then utilize the “Street” class to generate the entire street and visually plot each house. Each house will have a randomly assigned presence of a chimney, and they may produce smoke randomly as well.

To ensure the intelligent implementation of the graphics program, it is suggested to make use of efficient algorithms and data structures to handle the creation and visualization of houses. Further, appropriate object-oriented design principles and best practices should be followed to maintain code readability, modularity, and extensibility.

In conclusion, this assignment involves the design and implementation of two classes, “House” and “Street,” to represent houses on a street in a C++ program. The program will allow users to input the necessary information and plot the entire street, including the visual representation of each house and randomly generated smoke from the house chimneys. Careful consideration should be given to efficient algorithms, data structures, and intelligent implementation for the successful execution of the graphics program.

Need your ASSIGNMENT done? Use our paper writing service to score better and meet your deadline.

Click Here to Make an Order Click Here to Hire a Writer