A relationship of the random walks on one-dimensional periodic lattice and the correlation functions of the XX Heisenberg spin chain is investigated. The operator averages taken over the ferromagnetic state play a role of generating functions of the number of paths made by the so-called "vicious" random walkers (the vicious walkers annihilate each other provided they arrive at the same lattice site). It is shown that the two-point correlation function of spins, calculated over eigen-states of the XX magnet, can be interpreted as the generating function of paths made by a single walker in a medium characterized by a non-constant number of vicious neighbors. The answers are obtained for a number of paths made by the described walker from some fixed lattice site to another sufficiently remote one. Asymptotical estimates for the number of paths are provided in the limit, when the number of steps is increased.