





def 			lowerCAmelCase_			(				UpperCamelCase_       ,		UpperCamelCase_	)  ->		int:
       for index, item in enumerate(UpperCamelCase_	):
              if item == target:
                     return index
       return -1




def 			lowerCAmelCase_			(				UpperCamelCase_       ,		UpperCamelCase_       ,		UpperCamelCase_       ,		UpperCamelCase_	)  ->		int:
       if not (0 <= high < len(UpperCamelCase_	) and 0 <= low < len(UpperCamelCase_	)):
              raise Exception("Invalid upper or lower bound!"	)
       if high < low:
              return -1
       if sequence[low] == target:
              return low
       if sequence[high] == target:
              return high
       return rec_linear_search(UpperCamelCase_       ,		low + 1       ,		high - 1       ,		UpperCamelCase_	)


if __name__ == "__main__":
     _UpperCAmelCase										=					input('Enter numbers separated by comma:\n').strip()
     _UpperCAmelCase										=					[int(item.strip()) for item in user_input.split(',')]

     _UpperCAmelCase										=					int(input('Enter a single number to be found in the list:\n').strip())
     _UpperCAmelCase										=					linear_search(sequence, target)
     if result != -1:
          print(f'''linear_search({sequence}, {target}) = {result}''')
     else:
          print(f'''{target} was not found in {sequence}''')








from itertools import compress, repeat
from math import ceil, sqrt




def 			lowerCAmelCase_			(				UpperCamelCase_	)  ->		list[int]:

       if num <= 2:
              return []
       if num == 3:
              return [2]

       # Odd sieve for numbers in range [3, num - 1]
       UpperCamelCase_ 							=	bytearray(b"\x01"	) * ((num >> 1) - 1)

       for i in range(3       ,		int(sqrt(UpperCamelCase_	)	) + 1       ,		2	):
              if sieve[(i >> 1) - 1]:
                     UpperCamelCase_ 							=	i**2
                     UpperCamelCase_ 							=	repeat(
                         0       ,		ceil((num - i_squared) / (i << 1)	)	)

       return [2] + list(compress(range(3       ,		UpperCamelCase_       ,		2	)       ,		UpperCamelCase_	)	)


if __name__ == "__main__":
     import doctest

     doctest.testmod()

