The set of all linear recurrence relations satisfied by given sequences of finite length is described by the annihilator ideal of the sequences. The MasseyDing algorithm to compute a linear recurrence relation of minimal order for several finite sequences of equal length is generalized to compute a minimal Gro¨ bner basis of the annihilator ideal of several finite sequences of generally different lengths.