def        lowercase(     UpperCamelCase_    )						->     Any:







 '''simple docstring'''
 if not isinstance(UpperCamelCase_				, UpperCamelCase_    ) or number < 0:
  raise ValueError("""Input must be a non-negative integer"""    )

 UpperCamelCase          =	0
 while number:
  # This way we arrive at next set bit (next 1) instead of looping
  # through each bit and checking for 1s hence the
  # loop won't run 32 times it will only run the number of `1` times
  number &= number - 1
  count += 1
 return count


if __name__ == "__main__":
     import doctest

     doctest.testmod()

"""simple docstring"""






from PIL import Image



def   a_						(					lowerCamelCase					,			lowerCamelCase       ):
				UpperCAmelCase__             =							(2_5_9 * (level + 2_5_5)) / (2_5_5 * (2_5_9 - level))

				def contrast(lowerCamelCase       ) -> int:
								return int(1_2_8 + factor * (c - 1_2_8)       )

				return img.point(lowerCamelCase       )


if __name__ == "__main__":
						# Load image
						with Image.open('image_data/lena.jpg') as img:
												# Change contrast to 170
												lowerCAmelCase__  :  Any						     =	change_contrast(img, 170)
												cont_img.save('image_data/lena_high_contrast.png', format='png')



