Unique random variables. I've tried modifying the code in varying ways, but nothing is working. The program won't add new numbers to replace the ones that were duplicates.
import random
b=0
numbers=[]
print "show 6 random unique integers from 1 to 50: "
while b < 6:
for k in range(6):
k = random.randint(1,10)
numbers.append(k)
b=b+1
setA = set(numbers)
numbers = list(setA)
print numbers
It's getting silly now.