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:状态空间搜索BFS

Posted by lddyun at 2010-08-16 21:14:01 on Problem 1426
In Reply To:状态空间搜索BFS Posted by:new_star at 2008-07-31 11:40:31
> 状态表示:     mult对n的余数
> 状态集合: A = { 0, 1, 2, ..., n-1 }, |A| <= 200
> 初始状态:   1
> 终点状态: 0
> 
> 对状态S的扩展运算为
> newS = (10*s)%n;
> if ( !used[newS] ) {
>     queue.push( newS );
>     used[newS] = true;
> }

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