Changed for loop and rand array