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:bsearchIn Reply To:bsearch Posted by:20053565 at 2008-02-10 16:59:10 for(j=0;j<n-1;j++) > for(k=j+1;k<n;k++) > { > if(s[k]>s[j]) > { > t=s[j]; > s[j]=s[k]; > s[k]=s[j]; > } > if(s[k]==s[j]) > s[k]=0; > } TLE原因就在这里面,时间复杂度过大 Followed by: Post your reply here: |
All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator