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

不用打表

Posted by chenyukang at 2010-06-21 21:40:01 on Problem 2265
计算出x在第p层的第t个,初始 (x,y) 为(p,0)
按照这个顺序每个方向走p次,同时t--,直到t==0时候结束。
int D[6][2]={
    {-1,1},{-1,0},
    {0,-1},{1,-1},
    {1,0},{0,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