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 2003011475 at 2007-04-26 16:35:53 on Problem 1906
In Reply To:好象全排列,但要不要高精啊?? Posted by:fjnu_jxd_010 at 2005-08-21 13:58:18
应该要高精度,因为__int64没法存19位的十位数。另外,全排列可能会花很长时间。我是采用了一种类似进位制的方法,先把输入的n减1再转化成二进制,然后看哪几位为1,输出3的对应次幂。具体关系自己慢慢看吧,:)

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