I need help to make a schedule on dev C++
This is the code that i have right now
This is in my main.cpp
/**********************************************************************************************************
<project firstname="Your Firstname" lastname="Your lastname" projname="SCHEDULER" />
Purpose of Program:
Pseudo Code:
***********************************************************************************************************/
void DisplaySchedule(vector<Schedule> schs)
{
cout<<"-----------------------------CURRENT SCHEDULE----------------------------------------------------\n\n";
for(int i=0;i<schs.size();i++)
{
cout<<"----------------------------------------------------------------------------------\n";
cout<<(i+1)<<".";
schs[i].Display();
}
cout<<endl;
}
/* run this program using the console pauser or add your own getch, system("pause") or input loop */
int main(int argc, char** argv) {
//FILL IN THE CODES
return 0;
}
And this is in another file name Schedule.h
/********************DR. SUNMONU ************************************
Time and Schedule program, 2/9/19
*********************************************************************/
#pragma once
#include <iostream>
#include <iomanip>
#include <string>
using namespace std;
struct Time
{
int Hour;
int Minute;
int Second;
Time():Time(0,0,0){ } //default constructor - "calls" constructor with parameters
Time(int hr, int min, int sec) //constructor with parameters
{
Hour = hr;
Minute = min;
Second = sec;
};
//read time from user
void ReadTime()
{
}
//show time
void Show()
{
cout<<Hour<<":"<<Minute<<":"<<Second;
}
};
class Schedule
{
public:
Schedule(string day, Time start, Time end, string activity);
void Display();
void Length();//calculates the duration of the schedule
void ReadSchedule();//read schedule from user
private:
string Day;
Time Start; //start of schedule
Time End; //end of schedule
string Activity;
};
Schedule::Schedule(string day, Time start, Time end, string activity)
{
//FILL IN THE CODE
}
//read schedule from user
void Schedule::ReadSchedule()
{
//FILL IN THE CODE
}
//calculate the difference between start and end time in hours, minutes and seconds
void Schedule::Length()
{
//FILL IN THE CODE
}
The parts that say fill in code are the parts i can not figure out
This is the description of the project
Write a C++ program to display workers schedule for a company. To accomplish this
(1) Write a struct Time with attributes (at least) : hours, minutes and seconds. Add other functions or attributes you need to get the job done
(2) Write a class Schedule with attributes : Day of week, start_time, end_time and activity.
Schedule should have at least (a) Display to display the schedule (b) Length to return the duration of the schedule (ie end_time - start_time), (c) ReadSchedule to read schedule from user
(2b) Your program must check that only appropriate numbers are entered for Time in ReadSchedule (default value for hour/minute and second is 0)
(2c) Your program should indicate error when end_time < start_time.
(3) You should store the schedules in a vector
(4) Create the struct Time and class Schedule in a file named schedule.h which you must include in main.cpp