make c program with following required variables

  • Create a static variable to keep track of how may room objects the program creates.
  • Create a friendly class ‘Hallway’ that has access to the members of room.
  • Add a new private member to the room class ‘type’ that is a pointer to char. the room type can be ‘K’, ‘R’ or ‘L’ or ‘B'(Kitchen, Restroom, Bedroom or Living room)
  • Create 2 rooms objects room1 and room2 and assign (memberwise assignment room1=room2)
  • Define a copy constructor that prevent both rooms point at the same char.
  • submit all the code in a file

0 replies

Leave a Reply

Want to join the discussion?
Feel free to contribute!

Leave a Reply

Your email address will not be published. Required fields are marked *