



import sys



def        __a     (    lowerCAmelCase_   :					int			,lowerCAmelCase_   :					list[int]				)      -> int:






						'''simple docstring'''



						if not numbers:
												return 0
						if target == 0 and target in numbers:
												return 0
						if not isinstance(lowerCAmelCase_			,(list, tuple)				) or not all(
						    isinstance(lowerCAmelCase_			,lowerCAmelCase_				) for number in numbers				):
												raise ValueError("""numbers must be an iterable of integers"""				)

						UpperCAmelCase_=   UpperCAmelCase_=   UpperCAmelCase_=   0
						UpperCAmelCase_=   sys.maxsize

						while right < len(lowerCAmelCase_				):
												curr_sum += numbers[right]
												while curr_sum >= target and left <= right:
																		UpperCAmelCase_=   min(lowerCAmelCase_			,right - left + 1				)
																		curr_sum -= numbers[left]
																		left += 1
												right += 1

						return 0 if min_len == sys.maxsize else min_len









def        __a     (    lowerCAmelCase_   :					list				)      -> bool:






						'''simple docstring'''



						if not isinstance(lowerCAmelCase_			,lowerCAmelCase_				):
												raise ValueError("""Input series is not valid, valid series - [1, 2/3, 2]"""				)
						if len(lowerCAmelCase_				) == 0:
												raise ValueError("""Input list must be a non empty list"""				)
						if len(lowerCAmelCase_				) == 1 and series[0] != 0:
												return True
						UpperCAmelCase_=   []
						UpperCAmelCase_=   len(lowerCAmelCase_				)
						for i in range(0			,lowerCAmelCase_				):
												if series[i] == 0:
																		raise ValueError("""Input series cannot have 0 as an element"""				)
												rec_series.append(1 / series[i]				)
						UpperCAmelCase_=   rec_series[1] - rec_series[0]
						for index in range(2			,lowerCAmelCase_				):
												if rec_series[index] - rec_series[index - 1] != common_diff:
																		return False
						return True



def        __a     (    lowerCAmelCase_   :					list				)      -> float:






						'''simple docstring'''



						if not isinstance(lowerCAmelCase_			,lowerCAmelCase_				):
												raise ValueError("""Input series is not valid, valid series - [2, 4, 6]"""				)
						if len(lowerCAmelCase_				) == 0:
												raise ValueError("""Input list must be a non empty list"""				)
						UpperCAmelCase_=   0
						for val in series:
												answer += 1 / val
						return len(lowerCAmelCase_				) / answer


if __name__ == "__main__":
	import doctest

	doctest.testmod()




