Codeforces 1283A Minutes Before the New Year

题目链接:

Codeforces 1283A Minutes Before the New Year

思路:

照意思计算输出即可

代码:

#include<bits/stdc++.h>
using namespace std;
typedef pair<int,int> P;
typedef long long ll;
#define fi first
#define sc second
#define pb(a) push_back(a)
#define mp(a,b) make_pair(a,b)
#define pt(a) cerr<<a<<"---
"
#define rp(i,n) for(int i=0;i<n;i++)
#define rpn(i,n) for(int i=1;i<=n;i++)
int main(){
	ios::sync_with_stdio(false); cin.tie(nullptr);
	int t; cin>>t;
	while(t--){
		int h,m; cin>>h>>m;
		cout<<(23-h)*60+(60-m)<<'
';
	}
	return 0;
}
原文地址:https://www.cnblogs.com/yuhan-blog/p/12308714.html