human
What is a code to product of non and the other steps required given the following:
Product of non | Function to find the product of all non - repeated elements in an array.
sort all elements of array.
Driver code"
How can the above be solved in Python?
assistant
#Here is code to product of non and the other steps required.
 def findProduct ( arr , n ) :
	sorted ( arr )
	prod = 1
	for i in range ( 0 , n , 1 ) :
		if ( arr [ i - 1 ] != arr [ i ] ) :
			prod = prod * arr [ i ]
	return prod ;
if __name__ == ' _ _ main _ _ ' :
	arr = [ 1 , 2 , 3 , 1 , 1 , 4 , 5 , 6 ]
	n = len ( arr )
	print ( findProduct ( arr , n ) )