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:为便于理解,给组反例,详见内.

Posted by answer_allon at 2008-02-27 09:35:07 on Problem 1013
In Reply To:为便于理解,给组反例,详见内. Posted by:ferret_chao at 2005-10-12 12:28:54
这种方案可以吧。用两个数组变量来存放权重: int left[12],right[12]. "even"时就对两个都操作。"up", 左边出现的字符i在对应的left[i]进行+1 , 右边的字符j在对应的right[j]进行+1. 最后比较两数组中得到最大的,顺便判断轻重。

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