#32704: 最基礎的解法 C++ AC


yp11151097@yphs.tp.edu.tw (808-30施耀登)

學校 : 臺北市私立延平高級中學
編號 : 197083
來源 : [203.72.178.1]
最後登入時間 :
2023-06-09 13:54:26
a244. 新手訓練 ~ for + if -- 新手訓練系列 ~ 1 | From: [203.72.178.2] | 發表日期 : 2022-10-28 13:42

#include<iostream>
using namespace std;
int main(){
long long int a,b,c,n;
while(cin>>n){
	while(cin>>a>>b>>c){
	a>1<=4;
	if(a==1){
		cout<<b+c<<endl;
	}
	else if(a==2){
		cout<<b-c<<endl;
	}
	else if(a==3){
		cout<<b*c<<endl;
	}
	else cout<<b/c<<endl;
}
}
  return 0;
}
//最基礎的解法
 
ZeroJudge Forum