code: 
  
  
  
  
  
  '''simple docstring'''
  
  
  
  
  
  
  
  class 					_UpperCAmelCase							:
  		def __init__(						self    ):
  
  
  
  					'''simple docstring'''
  
  					__lowerCAmelCase      		=       {}
  					# indexmap keys are an index and it's values are the number at that index
  					__lowerCAmelCase      		=       {}
  		def 						lowerCamelCase__    (						self,__SCREAMING_SNAKE_CASE,__SCREAMING_SNAKE_CASE    ):
  
  
  
  					'''simple docstring'''
  
  					if isinstance(__SCREAMING_SNAKE_CASE,(range, str)    ):
  								__lowerCAmelCase      		=       list(__SCREAMING_SNAKE_CASE    )
  					elif not isinstance(__SCREAMING_SNAKE_CASE,__SCREAMING_SNAKE_CASE    ):
  								raise TypeError(
  								    """binary_search_delete() only accepts either a list, range or str"""    )
  
  					__lowerCAmelCase      		=       0
  					__lowerCAmelCase      		=       len(__SCREAMING_SNAKE_CASE    ) - 1
  
  					while low <= high:
  								__lowerCAmelCase      		=       (low + high) // 2
  								if array[mid] == item:
  											array.pop(__SCREAMING_SNAKE_CASE    )
  											return array
  								elif array[mid] < item:
  											__lowerCAmelCase      		=       mid + 1
  								else:
  											__lowerCAmelCase      		=       mid - 1
  					raise ValueError(
  					    """Either the item is not in the array or the array was unsorted"""    )
  		def 						lowerCamelCase__    (						self,__SCREAMING_SNAKE_CASE,__SCREAMING_SNAKE_CASE    ):
  
  
  
  					'''simple docstring'''
  
  					if isinstance(__SCREAMING_SNAKE_CASE,(range, str)    ):
  								__lowerCAmelCase      		=       list(__SCREAMING_SNAKE_CASE    )
  					elif not isinstance(__SCREAMING_SNAKE_CASE,__SCREAMING_SNAKE_CASE    ):
  								raise TypeError(
  								    """binary_search_insert() only accepts either a list, range or str"""    )
  
  					__lowerCAmelCase      		=       0
  					__lowerCAmelCase      		=       len(__SCREAMING_SNAKE_CASE    ) - 1
  
  					while low <= high:
  								__lowerCAmelCase      		=       (low + high) // 2
  								if array[mid] == index:
  											# If the item already exists in the array,
  											# insert it after the existing item
  											array.insert(mid + 1,__SCREAMING_SNAKE_CASE    )
  											return array
  								elif array[mid] < index:
  											__lowerCAmelCase      		=       mid + 1
  								else:
  											__lowerCAmelCase      		=       mid - 1
  
          # If the item doesn't exist in the array, insert it at the appropriate position
  					array.insert(__SCREAMING_SNAKE_CASE,__SCREAMING_SNAKE_CASE    )
  					return array
  		def 						lowerCamelCase__    (						self,__SCREAMING_SNAKE_CASE,__SCREAMING_SNAKE_CASE    ):
  
  
  
  					'''simple docstring'''
  
  					if index in self.indexmap:
  								__lowerCAmelCase      		=       self.indexmap[index]
  								if len(self.numbermap[n]    ) == 1:
  											del self.numbermap[n]
  								else:
  											__lowerCAmelCase      		=       self.binary_search_delete(self.numbermap[n],__SCREAMING_SNAKE_CASE    )
  
          # Set new index
  					__lowerCAmelCase      		=       number
  
  					# Number not seen before or empty so insert number value
  					if number not in self.numbermap:
  								__lowerCAmelCase      		=       [index]
  
  					# Here we need to perform a binary search insertion in order to insert
  					# The item in the correct place
  					else:
  								__lowerCAmelCase      		=       self.binary_search_insert(
  								    self.numbermap[number],__SCREAMING_SNAKE_CASE    )
  
  
  
  
  
  
  
  		def 						lowerCamelCase__    (						self,__SCREAMING_SNAKE_CASE    ):
  
  
  
  					'''simple docstring'''
  
  					return self.numbermap.get(__SCREAMING_SNAKE_CASE,[-1]    )[0]
  
  
  if __name__ == "__main__":
  	import doctest
  
  	doctest.testmod()
  
  
  
style_context: 
  
  
  
  
  
  '''simple docstring'''
  
  
  
  
  
  
  
  def      _lowerCAmelCase		(		lowercase = 1000			)      ->      int:
  			__lowerCAmelCase      		=       []
  			__lowerCAmelCase      		=       []
  			__lowerCAmelCase      		=       3
  			__lowerCAmelCase      		=       5
  			__lowerCAmelCase      		=       1
  			while True:
  						__lowerCAmelCase      		=       z * temp
  						if result < n:
  									zmulti.append(lowercase			)
  									temp += 1
  						else:
  									__lowerCAmelCase      		=       1
  									break
  			while True:
  						__lowerCAmelCase      		=       x * temp
  						if result < n:
  									xmulti.append(lowercase			)
  									temp += 1
  						else:
  									break
  			__lowerCAmelCase      		=       list(set(xmulti + zmulti			)			)
  			return sum(lowercase			)
  
  
  if __name__ == "__main__":
  	print(f'{solution() = }')
  
  