fork download
  1. #include<bits/stdc++.h>
  2. using namespace std;
  3. #define el "\n"
  4. #define ll long long
  5. #define ull unsigned long long
  6. #define se second
  7. #define fi first
  8. #define be begin()
  9. #define en end()
  10. #define Faster cin.tie(0); cout.tie(0); ios_base::sync_with_stdio(0);
  11. struct Time
  12. {
  13. int hr, mn;
  14. };
  15. Time tong(const Time& tm1, const Time& tm2)
  16. {
  17. int tmp = tm1.hr * 60 + tm1.mn + tm2.hr * 60 + tm2.mn;
  18. Time ans;
  19. ans.hr = tmp / 60;
  20. ans.mn = tmp % 60;
  21. return ans;
  22. }
  23. bool ssLonHon(const Time& tm1, const Time& tm2)
  24. {
  25. int tmp1 = tm1.hr * 60 + tm1.mn;
  26. int tmp2 = tm2.hr * 60 + tm2.mn;
  27. if(tmp1 > tmp2) return true;
  28. else return false;
  29. }
  30. int main()
  31. {
  32. Faster;
  33.  
  34. }
  35.  
Success #stdin #stdout 0s 5280KB
stdin
Standard input is empty
stdout
Standard output is empty