Codice PHP:
<pre>
<?php
$min 
1;
$max 30;
$num 10
print_r(array_rand(array_flip(range($min$max)), $num)); 
?>
</pre>