So, you want to sample 5 sets of 5 numbers, all from the same set, but you want them to be unique? (The technical description would be to sample without replacement.)
The point is, you already know how to sample 5 such numbers. So just sample 25 numbers!
r = reshape(randperm(900,25) + 99,[5 5]);
There is no reason to need a loop.