TIP:
The personal preferences variable named num, aimnum, loopnum, aim or the like, may be self renamed
The second question
import random
arr =[]
loopnum =0
while loopnum <= 9:
num = random.randint(1,1001)
arr.append(num)
loopnum = loopnum +1
del arr[4]
arr.insert(4, 2428)
print(arr)