
'''simple docstring'''




from __future__ import annotations







def 		lowerCAmelCase_				(   snake_case__		,				snake_case__						):




    '''simple docstring'''



    A       :   list[list[int]]					=						[]
    create_all_state(1		,				snake_case__		,				snake_case__		,				[]		,				snake_case__						)
    return result







def 		lowerCAmelCase_				(   snake_case__		,				snake_case__		,				snake_case__		,				snake_case__		,				snake_case__		,				):




    '''simple docstring'''



    if level == 0:
        total_list.append(current_list[:]						)
        return

    for i in range(snake_case__		,				total_number - level + 2						):
        current_list.append(snake_case__						)
        create_all_state(i + 1		,				snake_case__		,				level - 1		,				snake_case__		,				snake_case__						)
        current_list.pop()







def 		lowerCAmelCase_				(   snake_case__						):




    '''simple docstring'''



    for i in total_list:
        print(*snake_case__						)


if __name__ == "__main__":
      lowercase			:				Any    		=			4
      lowercase			:				Any    		=			2
      lowercase			:				str    		=			generate_all_combinations(n, k)
      print_all_state(total_list)










import math
import sys



def 					UpperCAmelCase__     (   lowerCamelCase      ):
  if number != int(lowerCamelCase      ):
    raise ValueError("the value of input must be a natural number"      )
  if number < 0:
    raise ValueError("the value of input must not be a negative number"      )
  if number == 0:
    return 1
  lowercase			:Dict							=  [-1] * (number + 1)
  lowercase			:Optional[Any]							=  0
  for i in range(1,	number + 1      ):
    lowercase			:Optional[int]							=  sys.maxsize
    lowercase			:Any							=  int(math.sqrt(lowerCamelCase      )      )
    for j in range(1,	root + 1      ):
      lowercase			:Any							=  1 + answers[i - (j**2)]
      lowercase			:Dict							=  min(lowerCamelCase,	lowerCamelCase      )
    lowercase			:Union[str, Any]							=  answer
  return answers[number]


if __name__ == "__main__":
     import doctest

     doctest.testmod()



