



import unittest

from knapsack import knapsack as k



class     UpperCAmelCase_       (			unittest.TestCase):







							def   snake_case__ (  self):

														'''simple docstring'''

														_lowerCAmelCase	:				Union[str, Any]					  =       0
														_lowerCAmelCase	:				Dict					  =       [0]
														_lowerCAmelCase	:				List[Any]					  =       [0]
														_lowerCAmelCase	:				Dict					  =       len(lowerCAmelCase_)
														self.assertEqual(k.knapsack(lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_),     0)

														_lowerCAmelCase	:				Optional[int]					  =       [60]
														_lowerCAmelCase	:				Union[str, Any]					  =       [10]
														_lowerCAmelCase	:				int					  =       len(lowerCAmelCase_)
														self.assertEqual(k.knapsack(lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_),     0)







							def   snake_case__ (  self):

														'''simple docstring'''

														_lowerCAmelCase	:				str					  =       3
														_lowerCAmelCase	:				Optional[int]					  =       [1, 2, 3]
														_lowerCAmelCase	:				List[str]					  =       [3, 2, 1]
														_lowerCAmelCase	:				Optional[Any]					  =       len(lowerCAmelCase_)
														self.assertEqual(k.knapsack(lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_),     5)







							def   snake_case__ (  self):

														'''simple docstring'''

														_lowerCAmelCase	:				Optional[Any]					  =       50
														_lowerCAmelCase	:				Optional[int]					  =       [60, 100, 120]
														_lowerCAmelCase	:				Union[str, Any]					  =       [10, 20, 30]
														_lowerCAmelCase	:				List[Any]					  =       len(lowerCAmelCase_)
														self.assertEqual(k.knapsack(lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_,     lowerCAmelCase_),     220)


if __name__ == "__main__":
						unittest.main()




'''simple docstring'''





import math






def 						UpperCAmelCase__(				_SCREAMING_SNAKE_CASE					: int ):






			"""simple docstring"""




			if not isinstance(_SCREAMING_SNAKE_CASE,_SCREAMING_SNAKE_CASE ):
						__A=	f"""Input value of [number={number}] must be an integer"""
						raise TypeError(_SCREAMING_SNAKE_CASE )

			if number < 1:
						__A=	f"""Input value of [number={number}] must be > 0"""
						raise ValueError(_SCREAMING_SNAKE_CASE )
			elif number == 1:
						return 3
			elif number == 2:
						return 5
			else:
						__A=	int(math.log(number // 3,2 ) ) + 2

						__A=	[3, 5]
						__A=	2
						__A=	3
						for block in range(1,_SCREAMING_SNAKE_CASE ):
									for _ in range(_SCREAMING_SNAKE_CASE ):
												proth_list.append(2 ** (block + 1) + proth_list[proth_index - 1] )
												proth_index += 1
									increment *= 2

			return proth_list[number - 1]


if __name__ == "__main__":
					import doctest

					doctest.testmod()

					for number in range(1_1):
										UpperCAmelCase__  			=				0
										try:
															UpperCAmelCase__  			=				proth(number)
										except ValueError:
															print(F"""ValueError: there is no {number}th Proth number""")
															continue

										print(F"""The {number}th Proth number: {value}""")



