Let X be an irreducible, discrete-time Markov chain an a finite set E, star
ting at some point i is an element of E. At each return time to i, the loop
-erasing procedure yields a random cycle which is simple (i.e. without subc
ycle) and contains i. Let T be the first rime at which this random simple c
ycle is Hamiltonian, i.e, contains all the points off. We determine the joi
nt law of this Hamiltonian cycle and of the occupation measure at time T an
d prove that this law does not depend on i. Furthermore, suppose that that
the transition probabilities p(., .') are invariant under the action of a g
roup G: for all x, y is an element of E and every g is an element of G, p(x
, y) = p(gx, gy). Then the law of the occupation measure at T is also invar
iant under the action of G. This generalizes a result of Pitman [5] for ran
dom walks on the circle. (C) 1999 Academie des sciences/Editions scientifiq
ues et medicales Elsevier SAS.