fork download
  1. // mytime1.h -- Time class before operator overloading
  2. #ifndef MYTIME1_H_
  3. #define MYTIME1_H_
  4.  
  5. class Time
  6. {
  7. private:
  8. int hours;
  9. int minutes;
  10. public:
  11. Time();
  12. Time(int h, int m = 0);
  13. void AddMin(int m);
  14. void AddHr(int h);
  15. void Reset(int h = 0, int m = 0);
  16. Time operator+(const Time & t) const;
  17. void Show() const;
  18. };
  19. #endif
  20.  
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
Standard input is empty
compilation info
/usr/lib/gcc/i586-linux-gnu/5/../../../i386-linux-gnu/crt1.o: In function `_start':
(.text+0x18): undefined reference to `main'
collect2: error: ld returned 1 exit status
stdout
Standard output is empty