P15339 Labour Laws 题解
思路
水红。 分类讨论即可。
代码
AC Code
#include<bits/stdc++.h>
using namespace std;
int main(){
int t;
cin>>t;
if(t>645)cout<<t-600;
else if(t>585)cout<<45;
else if(t>570)cout<<t-540;
else if(t>390)cout<<30;
else if(t>360)cout<<t-360;
else cout<<0;
return 0;
}