





from __future__ import annotations

from typing import Any

class  _UpperCAmelCase				:
      def __init__(		self   ,							a__ = 6							):
         A_  :					str         =						None
         A_  :					int         =						None
         self.create_linked_list(__UpperCamelCase							)
      def 		_lowerCamelCase   (		self   ,							a__							):
         A_  :					List[str]         =						Node()
         A_  :					List[str]         =						current_node
         A_  :					Optional[Any]         =						current_node
         A_  :					Optional[Any]         =						current_node
         for _ in range(1   ,							__UpperCamelCase							):
            A_  :					Any         =						Node()
            A_  :					Any         =						current_node
            A_  :					int         =						previous_node
            A_  :					Tuple         =						current_node
         A_  :					int         =						self.front
         A_  :					Union[str, Any]         =						previous_node
      def 		_lowerCamelCase   (		self							):
         return (
             self.front == self.rear
             and self.front is not None
             and self.front.data is None
         )
      def 		_lowerCamelCase   (		self							):
         self.check_can_perform_operation()
         return self.front.data if self.front else None
      def 		_lowerCamelCase   (		self   ,							a__							):






         if self.rear is None:
            return

         self.check_is_full()
         if not self.is_empty():
            A_  :					Tuple         =						self.rear.next
         if self.rear:
            A_  :					str         =						data
      def 		_lowerCamelCase   (		self							):
         self.check_can_perform_operation()
         if self.rear is None or self.front is None:
            return None
         if self.front == self.rear:
            A_  :					Dict         =						self.front.data
            A_  :					str         =						None
            return data

         A_  :					int         =						self.front
         A_  :					str         =						old_front.next
         A_  :					Any         =						old_front.data
         A_  :					List[str]         =						None
         return data
      def 		_lowerCamelCase   (		self							):






         if self.is_empty():
            raise Exception("""Empty Queue"""							)






      def 		_lowerCamelCase   (		self							):






         if self.rear and self.rear.next == self.front:
            raise Exception("""Full Queue"""							)






class  _UpperCAmelCase				:
      def __init__(		self							):
         A_  :					Dict         =						None
         A_  :					List[Any]         =						None
         A_  :					str         =						None


if __name__ == "__main__":
      import doctest

      doctest.testmod()








"""simple docstring"""



def 			_UpperCamelCase						(    _A   )     ->	int:





    """simple docstring"""

    if not isinstance(_A       ,   _A   ) 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()