csansoon

P1.11 P70955 How many seconds are they?

Sep 19th, 2018
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.26 KB | None | 0 0
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main() {
  6.     int years, days, hours, minutes, seconds;
  7.     cin >> years >> days >> hours >> minutes >> seconds;
  8.     cout << ((years*365*24*60*60)+(days*24*60*60)+(hours*60*60)+(minutes*60)+seconds) << endl;
  9. }
Advertisement
Add Comment
Please, Sign In to add comment