import numpy as np
array = np.zeros((10,10))
n = 5 # Generate n random values
values = np.random.rand(n)
# Reshape the array and shuffle its indices
array = np.reshape(array, -1)
shuffled_indices = np.random.permutation(10*10)[:n]
#Assign the random values to the selected indices
array[shuffled_indices] = values
array = np.reshape(array, (10, 10))
print(array)