human
Maximum height of triangular arrangement of array values | Python program to find the maximum height of Pyramidal Arrangement of array values.
Just checking whether ith level is possible or not if possible then we must have atleast ( i * ( i + 1 ) ) / 2 elements in the array.
updating the result value each time.
otherwise we have exceeded n value.
Driver Code"
Solution in Python:

What is a code to maximum height of triangular arrangement of array values and the other steps required?
assistant
#Here is code to maximum height of triangular arrangement of array values and the other steps required.
 def MaximumHeight ( a , n ) :
	result = 1
	for i in range ( 1 , n ) :
		y = ( i * ( i + 1 ) ) / 2
		if ( y < n ) :
			result = i
		else :
			break
	return result
arr = [ 40 , 100 , 20 , 30 ]
n = len ( arr )
print ( MaximumHeight ( arr , n ) )