




'''simple docstring'''

from __future__ import annotations


def 		__magic_name__    (	__UpperCAmelCase	)		->					list[int]:  # This function is recursive

					'''simple docstring'''

					snake_case_									=				len(__UpperCAmelCase	)
					# If the array contains only one element, we return it (it's the stop condition of
					# recursion)
					if array_length <= 1:
										return array
										# Else
					snake_case_									=				array[0]
					snake_case_									=				False
					snake_case_									=				1
					snake_case_									=				[]
					while not is_found and i < array_length:
										if array[i] < pivot:
															snake_case_									=				True
															snake_case_									=				[element for element in array[i:] if element >= array[i]]
															snake_case_									=				longest_subsequence(__UpperCAmelCase	)
															if len(__UpperCAmelCase	) > len(__UpperCAmelCase	):
																				snake_case_									=				temp_array
										else:
															i += 1

					snake_case_									=				[element for element in array[1:] if element >= pivot]
					snake_case_									=				[pivot, *longest_subsequence(__UpperCAmelCase	)]
					if len(__UpperCAmelCase	) > len(__UpperCAmelCase	):
										return temp_array
					else:
										return longest_subseq


if __name__ == "__main__":
							import doctest

							doctest.testmod()






"""simple docstring"""







def 				UpperCamelCase_    (    lowerCAmelCase__      :				int = 100						)						->   int:

  """simple docstring"""




  lowerCAmelCase_   :				Any								= (n * (n + 1) // 2) ** 2
  lowerCAmelCase_   :				Optional[int]								= n * (n + 1) * (2 * n + 1) // 6
  return sum_cubes - sum_squares


if __name__ == "__main__":
     print(f'{solution() = }')





