MATLAB: Generating random numbers without repitiion

no repititionrandome numbers

Hello all,
How can I generate, say 10, random numbers uniformly distributed between Nmin and Nmax, without repeating any one of them twice?
Thanks

Best Answer

Nmin+rand(1,10)*(Nmax-Nmin)
Related Question