Educational Codeforces Round 56—A. Dice Rolling

传送门

签到水题

不用讲了吧

直接除以2输出都可以了

 #include<bits/stdc++.h>
using namespace std;
#define ll long long
inline int read(){
	char ch=getchar();
	int res=0;
	while(!isdigit(ch))ch=getchar();
	while(isdigit(ch))res=(res<<3)+(res<<1)+(ch^48),ch=getchar();
	return res;
}
int n;
int main(){
	n=read();
	for(int i=1;i<=n;i++){
		int k=read();
		cout<<(k/2)<<'\n';
	}
} 

猜你喜欢

转载自blog.csdn.net/qq_42555009/article/details/85023303