CSCI 261 - Programming Concepts (C++)

Fall 2017 - Lab 8B

Quick Links: Canvas | CS @ Mines | Cloud9 | Piazza | zyBooks

|   Home |  Contact |  Syllabus |  Assignments |  Schedule |  Resources   |
This lab is due by Tuesday, November 21, 2017 11:59 PM .

Concepts



Focus on defining an Event class from scratch.


Suggestion: Use NotePad or WordPad



Consider using NotePad or WordPad on your computer to write your code for this lab. Once you feel good about what you've written, then copy the code into your project. Doing this will help you see where you might make mistakes on the exam!

You should write a main.cpp that tests each feature of your class works as expected. You will need to submit your class declaration file, your class definition file, and your main.cpp file for this lab with Assignment 8.


Event Class



Now that we have a way to represent a calendar date, we need a way to make entries into a calendar. Create a new class called Event that contains a data member of type Date from Lab 8A. In addition, add data members to track the event title and location. Functions you should include in your class:
  • A default constructor that sets the date to 12/30/1950 (with the corresponding title and location for extra credit).
  • A parameterized constructor that allows a user to enter a new date object, title, and location (such as "8/1/1876" and its corresponding info for extra credit).
  • Appropriate getter and setter functions. The Date setter should operate on a Date object and no longer the individual month, day, year pieces.
  • A print function that prints the details in the form: M/D/Y: Title (location).


Lab Submission



You will submit your solution to this lab with the rest of A8. Detailed instructions for doing this are posted in Assignment 8.


This lab is due by Tuesday, November 21, 2017 11:59 PM .
Last Updated: 11/05/17 20:56


Valid HTML 4.01 Strict Valid CSS! Level Triple-A conformance, W3C WAI Web Content Accessibility Guidelines 2.0