Problem Statement
有n (n <= 50) 个点,每个点每秒钟可以向上下左右移动一单位,
要求m(m <= 100000) 秒后所有点到同一点。求所有行动方案。
Wolf Sothe is a member of the wolf pack called Grid Walkers.
The N wolves in the pack are numbered 0 through N-1.
(Wolf Sothe is the wolf number 0, but this does not matter.)
At any moment, each wolf is located at some grid point in the plane.
Multiple wolves may share the same grid point.
For each i, the wolf number i is initially located at (x[i],y[i]).
Then there are exactly m rounds in which the wolves move.
In each round, each wolf must move from its current grid point to one of the four adjacent grid points.
More precisely, the wolf located at (i,j) has to move to (i+1,j), (i-1,j), (i,j+1), or (i,j-1).
The wolves have a goal: all of them have to be located at the same grid point after the m-th round.
The grid point at which they all meet is not given - they can choose any grid point.
You are given the int[]s x and y, and the int m.
Count and return the number of ways in which the wolves can reach their goal, modulo 1,000,000,007.
Two ways of reaching the goal are different if in some round the same wolf moves in a different direction.
(Equivalently, two ways of reaching the goal are different if there is some number of rounds x and a wolf y such that the grid point of the wolf y after x rounds of the first way differs from the grid point of the wolf y after x rounds of the second way.)