



def       A_   (						__a  :					List[str]			,		__a  :					List[Any]		):

				"""simple docstring"""
				if n < 0:
								return 0
				# table[i] represents the number of ways to get to amount i
				a__					   =		[0] * (n + 1)

				# There is exactly 1 way to get to zero(You pick no coins).
				a__					   =		1

				# Pick all coins one by one and update table[] values
				# after the index greater than or equal to the value of the
				# picked coin
				for coin_val in s:
								for j in range(__a			,		n + 1		):
												table[j] += table[j - coin_val]

				return table[n]


if __name__ == "__main__":
	import doctest

	doctest.testmod()




"""simple docstring"""




from __future__ import annotations



def 						UpperCAmelCase__ (					A__						,     A__						,     A__						,     A__ )   ->   None:




   """simple docstring"""
   lowerCamelCase__       ,							lowerCamelCase__						       =      m - 1, 0
   while i >= 0 and j < n:
      if key == mat[i][j]:
         print(f'Key {key} found at row- {i + 1} column- {j + 1}' )
         return
      if key < mat[i][j]:
         i -= 1
      else:
         j += 1
   print(f'Key {key} not found' )



def 						UpperCAmelCase__ (					)   ->   None:




   """simple docstring"""
   lowerCamelCase__						       =      [[2, 5, 7], [4, 8, 13], [9, 11, 15], [12, 17, 20]]
   lowerCamelCase__						       =      int(input("Enter the element to be searched:" ) )
   print(A__ )
   search_in_a_sorted_matrix(A__						,     len(A__ )						,     len(mat[0] )						,     A__ )


if __name__ == "__main__":
     import doctest

     doctest.testmod()
     main()




