您的位置:首页 > 其它

新手村 洛谷的第一个任务 小鱼的游泳时间

2017-10-28 19:38 399 查看
第一个任务还是很好写的。至于我为什么从头开始写呢。。因为我之前是用的USACO,切到第3章的时候写不下去了,看到这个里面把USACO放在了试炼场里面,于是想干脆直接拿洛谷的试炼场来写吧。。。

#include <cstring>
#include <iostream>
#include <cmath>
#include <stdio.h>
#include <stdlib.h>
#include <string>

using namespace std;

int main() {
int a, b, c, d;
cin >> a >> b >> c >> d;
int time = c * 60 + d - a * 60 - b;
cout << time / 60 << " " << time % 60 << endl;
return 0;
}
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: