Skip to content

Instantly share code, notes, and snippets.

@naruse naruse/Date.h
Created Dec 17, 2018

Embed
What would you like to do?
Date.h
#pragma once
using namespace::std;
class Date {
public:
int year;
int month;
int day;
int hour;
int minute;
Date(int yr, int mth, int dy, int hr, int mn) :
year(yr), month(mth), day(dy), hour(hr), minute(mn) {}
string ToString() {
return to_string(year) + " " + to_string(month) + " " + to_string(day) + " " + to_string(hour) + " " + to_string(minute);
}
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.