HMMT Combinatorics 2019/10: I wish I could walk for 40 minutes
Source:
February 17, 2019
HMMTcombinatorics
Problem Statement
Fred the Four-Dimensional Fluffy Sheep is walking in 4-dimensional space. He starts at the origin. Each minute, he walks from his current position to some position with integer coordinates satisfying
(x_1-a_1)^2 + (x_2-a_2)^2 + (x_3-a_3)^2 + (x_4-a_4)^2 = 4
\text{and}
|(x_1 + x_2 + x_3 + x_4) - (a_1 + a_2 + a_3 + a_4)| = 2.
In how many ways can Fred reach after exactly 40 minutes, if he is allowed to pass through this point during his walk?