Online JudgeProblem SetAuthorsOnline ContestsUser
Web Board
Home Page
F.A.Qs
Statistical Charts
Problems
Submit Problem
Online Status
Prob.ID:
Register
Update your info
Authors ranklist
Current Contest
Past Contests
Scheduled Contests
Award Contest
User ID:
Password:
  Register

Re:一道水题,卡了我半天。提供cmp代码以供参考,我用sort排序过的

Posted by dongchongxiacao at 2009-11-02 19:54:58 on Problem 2021
In Reply To:一道水题,卡了我半天。提供cmp代码以供参考,我用sort排序过的 Posted by:Ontheline at 2009-07-25 11:15:41
> int cmp(Descendant& n1,Descendant& n2)
> {
> 	if(n1.year!=n2.year)return n1.year>n2.year;
> 	else 
> 	{
> 		if(strcmp(n1.name,n2.name)==-1)return 1;
> 		else return 0;
> 		
> 	}
> }

Followed by:

Post your reply here:
User ID:
Password:
Title:

Content:

Home Page   Go Back  To top


All Rights Reserved 2003-2013 Ying Fuchen,Xu Pengcheng,Xie Di
Any problem, Please Contact Administrator