#include <iostream>
using namespace std;
class Time;
class Date
{
public:
Date(int ,int ,int);
void display(Time &);
private:
int day;
int month;
int year;
};
Date::Date(int d,int m,int y)
{
int day=d;
int month=m;
int year=y;
}
class Time
{
public:
Time(int,int,int);
friend void Date::display(Time &);
private:
int hour;
int minute;
int sec;
};
Time::Time(int h,int m,int s)
{
hour=h;
minute=m;
sec=s;
}
void Date::display(Time &t)
{
cout<<day<<" "<<month<<" "<<year<<endl;
cout<<t.hour<<" "<<t.minute<<" "<<t.sec<<endl;
}
int main()
{
Time t(10,13,56);
Date d(12,25,2004);
d.display(t);
return 0;
}