'''simple docstring'''

def       __UpperCamelCase	(       UpperCAmelCase					):

 if not isinstance(UpperCAmelCase		,					UpperCAmelCase					):
  raise ValueError('''multiplicative_persistence() only accepts integral values'''					)
 if num < 0:
  raise ValueError('''multiplicative_persistence() does not accept negative values'''					)

 lowercase__    :   Tuple						= 0
 lowercase__    :   int						= str(UpperCAmelCase					)

 while len(UpperCAmelCase					) != 1:
  lowercase__    :   List[Any]						= [int(UpperCAmelCase					) for i in num_string]

  lowercase__    :   Any						= 1
  for i in range(0		,					len(UpperCAmelCase					)					):
   total *= numbers[i]

  lowercase__    :   List[Any]						= str(UpperCAmelCase					)

  steps += 1
 return steps
def       __UpperCamelCase	(       UpperCAmelCase					):

 if not isinstance(UpperCAmelCase		,					UpperCAmelCase					):
  raise ValueError('''additive_persistence() only accepts integral values'''					)
 if num < 0:
  raise ValueError('''additive_persistence() does not accept negative values'''					)

 lowercase__    :   List[str]						= 0
 lowercase__    :   Tuple						= str(UpperCAmelCase					)

 while len(UpperCAmelCase					) != 1:
  lowercase__    :   Optional[Any]						= [int(UpperCAmelCase					) for i in num_string]

  lowercase__    :   Dict						= 0
  for i in range(0		,					len(UpperCAmelCase					)					):
   total += numbers[i]

  lowercase__    :   Any						= str(UpperCAmelCase					)

  steps += 1
 return steps


if __name__ == "__main__":
  import doctest

  doctest.testmod()


'''simple docstring'''

import numpy as np
def       __UpperCamelCase	(       UpperCAmelCase					):
 return 1 / (1 + np.exp(-vector					))
def       __UpperCamelCase	(       UpperCAmelCase					):
 return vector * sigmoid(UpperCAmelCase					)


if __name__ == "__main__":
  import doctest

  doctest.testmod()

