Online Judge | Problem Set | Authors | Online Contests | User | ||||||
---|---|---|---|---|---|---|---|---|---|---|
Web Board Home Page F.A.Qs Statistical Charts | Current Contest Past Contests Scheduled Contests Award Contest |
到底哪里错了:(#include<iostream.h> int main(){ int a,answer; cin>>a; for(int i=0;i<a;i++){ int num[4]; for(int j=0;j<4;j++) cin>>num[j]; if(num[3]-num[2]==num[2]-num[1]&&num[2]-num[1]==num[1]-num[0]) answer=2*num[3]-num[2]; answer=num[3]*num[3]/num[2]; cout<<num[0]<<" "<<num[1]<<" "<<num[2]<<" "<<num[3]<<" "<<answer<<endl; } return 0; } Followed by:
Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator