
"""simple docstring"""




import unittest

from knapsack import knapsack as k


class 			__magic_name__       (       unittest.TestCase ):
       def 							lowercase_							(     self       )     ->	List[Any]:





         """simple docstring"""




         _lowercase:			Optional[int]       =     0
         _lowercase:			Tuple       =     [0]
         _lowercase:			Any       =     [0]
         _lowercase:			Optional[int]       =     len(A_       )
         self.assertEqual(k.knapsack(A_ ,				A_ ,				A_ ,				A_       ) ,				0       )

         _lowercase:			List[Any]       =     [60]
         _lowercase:			List[Any]       =     [10]
         _lowercase:			Tuple       =     len(A_       )
         self.assertEqual(k.knapsack(A_ ,				A_ ,				A_ ,				A_       ) ,				0       )
       def 							lowercase_							(     self       )     ->	List[Any]:





         """simple docstring"""




         _lowercase:			str       =     3
         _lowercase:			List[Any]       =     [1, 2, 3]
         _lowercase:			Any       =     [3, 2, 1]
         _lowercase:			Union[str, Any]       =     len(A_       )
         self.assertEqual(k.knapsack(A_ ,				A_ ,				A_ ,				A_       ) ,				5       )



       def 							lowercase_							(     self       )     ->	int:





         """simple docstring"""




         _lowercase:			int       =     50
         _lowercase:			Any       =     [60, 100, 120]
         _lowercase:			Any       =     [10, 20, 30]
         _lowercase:			int       =     len(A_       )
         self.assertEqual(k.knapsack(A_ ,				A_ ,				A_ ,				A_       ) ,				220       )


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


"""simple docstring"""




def  _lowerCAmelCase		(		_UpperCamelCase						):






  """simple docstring"""



  if num <= 0:
    raise ValueError('''Input must be a positive integer'''						)

  _lowercase:			Tuple       =     [True] * (num + 1)

  _lowercase:			List[str]       =     2
  while p * p <= num:
    if primes[p]:
      for i in range(p * p ,				num + 1 ,				_UpperCamelCase						):
        _lowercase:			List[str]       =     False
    p += 1

  return [prime for prime in range(2 ,				num + 1						) if primes[prime]]


if __name__ == "__main__":
  import doctest

  doctest.testmod()

  A__   :					List[Any]							=   int(input('Enter a positive integer: ').strip())
  print(prime_sieve_eratosthenes(user_num))
