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 wangzh at 2008-06-09 22:59:38 on Problem 1051 and last updated at 2008-06-09 23:00:30
In Reply To:笨方法一个 Posted by:wrong123 at 2005-12-06 14:30:40
> 先根据定义创建一个表。
> 再:
> string s      ---存储输入串
> string store  ---存储encode成的莫斯玛 eg: “ ...-----...---......”
> int num[101]  ---存储每个编码的长度
> string result ---存储decode的结果
> 
> 之后:
> 
> 从store中,依次读入num[i](反方向)个字符,同时在表中查找对应的字符,
> 找到之后就  result.push_back();  一直到 num[0];
> 
> 最后: cout<<.......<<result<<endl;
> 
> 中间要注意比较的设计不能出错
多谢指点。过了

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