The understanding of inheritance and polymorphism

Assignment Help Computer Engineering
Reference no: EM132196169

Write a C++ program that will be an information system for Ohio Community College using classes as well as demonstrating a basic understanding of inheritance and polymorphism.

You will create a representation of an Ohio Community College information system that will contain information about the university. The university will contain a name of the university, n number of buildings, and m number of people. People can be either a student or an instructor. Every person will have a name and an age.

Every student will have also have a GPA, but an instructor will NOT have a GPA. Every instructor will have an instructor rating, but a student will NOT have an instructor rating. Every building will have a name, the size in sqft (2000 sqft), and an address (stored as a string, make one up).

People will contain a method called "do_work" that will take in a random integer as a parameter that represents how many hours they will do work for. If the person is a student, a message will be printed to the screen that says "PERSON_NAME did X hours of homework." If the person is an instructor, a message will be printed to the screen that says "Instructor PERSON_NAME graded papers for X hours." You will need to fill in the appropriate values.

The student GPA can either be an input from the user or randomized, but it must be between 0.0 and 4.0. It cannot be preset. The instructor rating can either be an input from the user or randomized, but it must be between 0.0 and 5.0. The ages of a person can be randomized or an input, but make it realistic. You can choose whether it is randomized or user input, or both.

The university will contain a method that will print the name and address of all the buildings in its information system and another method that will print the name of all the people. The name of the university MUST be "Ohio Community College" (because we are the best).

You will manually instantiate at least 1 student, 1 instructor, and 2 buildings, then give them values and store them appropriately in the university object. You can do this in whatever fashion you wish.

You will have a menu that does at least the following:

1) Prints names of all the buildings

2) Prints names of everybody at the university

3) Choose a person to do work

4) Exit the program

Note that option 3 will require you to print another menu that gives options for each person.

You may create any other functions, methods, member variables, etc. to modularize your code and complete the lab.

You may use vectors for this assignment if you so choose.

Reference no: EM132196169

Questions Cloud

Write about the protagonist and the war : Think about the book "A Long Way Gone", write about the protagonist and the war. The Movie "How to Make an American Quilt" delves into several characters'.
What is the value of stock today : After that, the firm expects to maintain a constant dividend growth rate of 2% per year. What is the value of this stock today if the required return is 14%?
How much do you need to invest today : If you deposit money now, you can earn 7% per annum with a 50% probability, 6% with a 25% probability and 8% with a 25% probability.
How does administrative law affect companies : What is administrative law? How does administrative law affect companies?
The understanding of inheritance and polymorphism : Write a C++ program that will be an information system for Ohio Community College using classes as well as demonstrating a basic understanding.
Role in ensuring the law is fulfilling its purpose : What about businesses - do they have a role in ensuring the law is fulfilling its purpose?
How do you believe syracuse university can help you : Who is the person you dream of becoming and how do you believe Syracuse University can help you achieve this?
Write a c program that implements the standard function : Write a C program that implements the standard function that returns the memory address of the first instance of string.
What is a service blueprint : What is a service blueprint, and how does a "poke-yoke" fit into the design of a service blueprint?

Reviews

Write a Review

Computer Engineering Questions & Answers

  Would it still need hardware memory address protection

Suppose we had a perfect object-oriented language and compiler, so that only an object's methods could access the internal data inside an object.

  Type of connections in elevator shaft

Describe what type of connections would work within the elevator shaft. If more than one choice is possible, choose the best option and describe the reasons for your choice.

  Complete the hostel location selection program

Based on the Windows form mock-up you created in Chapter 2, complete the Hostel Location Selection program by changing the window background color, downloading and adding the images

  Decompose the application using data flow diagrams

Decompose the application using data flow diagrams, system architecture diagrams, and a table describing the main components and users of the system;

  Create and test an html document that displays a table

Create and test an HTML document that displays a table of football scores from a collegiate football conference in which team names have one of primary colors.

  Define how does internet change information systems

The Internet may not make corporations obsolete, but they will have to change their business models

  How much of an area to leave uncut

One problem in timber management is to determine how much of an area to leave uncut so that the harvested area is reforested in a certain period of time.

  What would be problem with using one of other architectures

Which of the types of storage architectures discussed in this section would you expect. What would be the problem with using one of the other architectures in the data center environment?

  Routers concept

Suppose a BGPv4 router receives an update for the prefix P which indicates AS1 as the next hop (and router has never seen P before).

  Questioneither based on a present or past work project case

questioneither based on a present or past work project case study or fictitious project create a two-page project

  Explain computer programming is art or science

Which programming language appeals to you, and which language do you consider least appealing.

  Write a program that creates a number grid

Write a program that creates a number grid based on user input. A number grid is a sequence of integers organized into rows and columns.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd