

import math

import tensorflow as tf
from packaging import version
def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	Union[str, Any]      )							->      int:





    '''simple docstring'''






    A__          =   tf.convert_to_tensor(SCREAMING_SNAKE_CASE__      )
    A__          =   0.5 * (1.0 + tf.math.erf(x / tf.cast(tf.sqrt(2.0      )    ,			x.dtype      )      ))

    return x * cdf
def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	int      )							->      Optional[Any]:





    '''simple docstring'''






    A__          =   tf.convert_to_tensor(SCREAMING_SNAKE_CASE__      )
    A__          =   tf.cast(math.pi    ,			x.dtype      )
    A__          =   tf.cast(0.04_4715    ,			x.dtype      )
    A__          =   0.5 * (1.0 + tf.tanh(tf.sqrt(2.0 / pi      ) * (x + coeff * tf.pow(SCREAMING_SNAKE_CASE__    ,			3      ))      ))

    return x * cdf
def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	int      )							->      Optional[Any]:





    '''simple docstring'''






    A__          =   tf.convert_to_tensor(SCREAMING_SNAKE_CASE__      )

    return x * tf.tanh(tf.math.softplus(SCREAMING_SNAKE_CASE__      )      )
def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	Dict      )							->      int:





    '''simple docstring'''






    A__          =   tf.convert_to_tensor(SCREAMING_SNAKE_CASE__      )
    A__          =   tf.cast(0.04_4715    ,			x.dtype      )
    A__          =   tf.cast(0.79_7884_5608    ,			x.dtype      )

    return 0.5 * x * (1.0 + tf.tanh(x * coeffa * (1.0 + coeffa * x * x)      ))
def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	str      )							->      Union[str, Any]:





    '''simple docstring'''






    A__          =   tf.convert_to_tensor(SCREAMING_SNAKE_CASE__      )
    A__          =   tf.cast(1.702    ,			x.dtype      )
    return x * tf.math.sigmoid(coeff * x      )
def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	Optional[int]      )							->      Optional[int]:





    '''simple docstring'''






    return tf.clip_by_value(_gelu(SCREAMING_SNAKE_CASE__      )    ,			-10    ,			10      )
def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	Optional[int]    ,			SCREAMING_SNAKE_CASE__			:	Tuple=-1      )							->      List[Any]:





    '''simple docstring'''






    A__      ,						A__          =   tf.split(SCREAMING_SNAKE_CASE__    ,			2    ,			axis=SCREAMING_SNAKE_CASE__      )
    return a * tf.math.sigmoid(SCREAMING_SNAKE_CASE__      )


if version.parse(tf.version.VERSION) >= version.parse("2.4"):
     def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	List[str]      )							->      Dict:





         '''simple docstring'''






         return tf.keras.activations.gelu(SCREAMING_SNAKE_CASE__    ,			approximate=SCREAMING_SNAKE_CASE__      )

     lowercase_       		=  tf.keras.activations.gelu

     lowercase_       		=  approximate_gelu_wrap
else:
     lowercase_       		=  _gelu
     lowercase_       		=  _gelu_new


lowercase_       		=  {
    "gelu": gelu,
    "gelu_10": gelu_aa,
    "gelu_fast": gelu_fast,
    "gelu_new": gelu_new,
    "glu": glu,
    "mish": mish,
    "quick_gelu": quick_gelu,
    "relu": tf.keras.activations.relu,
    "sigmoid": tf.keras.activations.sigmoid,
    "silu": tf.keras.activations.swish,
    "swish": tf.keras.activations.swish,
    "tanh": tf.keras.activations.tanh,
}

def 						_snake_case(    SCREAMING_SNAKE_CASE__			:	Optional[int]      )							->      int:





    '''simple docstring'''






    if activation_string in ACTaFN:
        return ACTaFN[activation_string]
    else:
        raise KeyError(f'function {activation_string} not found in ACT2FN mapping {list(ACTaFN.keys()      )}'      )




import os

# Precomputes a list of the 100 first triangular numbers
lowercase_       		=  [int(0.5 * n * (n + 1)) for n in range(1, 101)]
def 						_snake_case(    )							->      int:





    '''simple docstring'''






    A__          =   os.path.dirname(os.path.realpath(SCREAMING_SNAKE_CASE__      )      )
    A__          =   os.path.join(SCREAMING_SNAKE_CASE__    ,			'words.txt'      )

    A__          =   ''
    with open(SCREAMING_SNAKE_CASE__      ) as f:
        A__          =   f.readline()

    A__          =   [word.strip('"'      ) for word in words.strip('\r\n'      ).split(','      )]
    A__          =   [
        word
        for word in [sum(ord(SCREAMING_SNAKE_CASE__      ) - 64 for x in word      ) for word in words]
        if word in TRIANGULAR_NUMBERS
    ]
    return len(SCREAMING_SNAKE_CASE__      )


if __name__ == "__main__":
     print(solution())

