| ||||||||||
| 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 | |||||||||
Re:太水了,两分钟写完代码ACIn Reply To:太水了,两分钟写完代码AC Posted by:986677841 at 2016-04-20 13:42:50 > #include<iostream>
> #include<cstdlib>
> #include<cstdio>
> #include<algorithm>
> using namespace std;
> const int maxn=10000+10;
> int p[maxn];
> int main(){
> int n;
> cin>>n;
> for(int i=0;i<n;i++)
> cin>>p[i];
> sort(p,p+n);
> cout<<p[n/2];
>
> return 0;
> }
Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator