洛谷刷题
p1405 小鱼的游泳时间
#include <iostream>
using namespace std;
int main()
{
int a,b,c,d;
cin>>a>>b>>c>>d;
int x=c-a,y=d-b;
if(y<0){x--;y+=60;}
cout<<x<<" "<<y;
return 0;
}
All articles in this blog are licensed under CC BY-NC-SA 4.0 unless stating additionally.
Comment