






'''simple docstring'''

from typing import TYPE_CHECKING

from ...file_utils import _LazyModule, is_torch_available
from ...utils import OptionalDependencyNotAvailable


UpperCAmelCase__						:Optional[int]          =			{
    """configuration_gpt_neox_japanese""": ["""GPT_NEOX_JAPANESE_PRETRAINED_CONFIG_ARCHIVE_MAP""", """GPTNeoXJapaneseConfig"""],
    """tokenization_gpt_neox_japanese""": ["""GPTNeoXJapaneseTokenizer"""],
}

try:
   if not is_torch_available():
      raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
   pass
else:
   UpperCAmelCase__						:Tuple          =			[
       """GPT_NEOX_JAPANESE_PRETRAINED_MODEL_ARCHIVE_LIST""",
       """GPTNeoXJapaneseForCausalLM""",
       """GPTNeoXJapaneseLayer""",
       """GPTNeoXJapaneseModel""",
       """GPTNeoXJapanesePreTrainedModel""",
   ]


if TYPE_CHECKING:
   from .configuration_gpt_neox_japanese import GPT_NEOX_JAPANESE_PRETRAINED_CONFIG_ARCHIVE_MAP, GPTNeoXJapaneseConfig
   from .tokenization_gpt_neox_japanese import GPTNeoXJapaneseTokenizer

   try:
      if not is_torch_available():
         raise OptionalDependencyNotAvailable()
   except OptionalDependencyNotAvailable:
      pass
   else:
      from .modeling_gpt_neox_japanese import (
          GPT_NEOX_JAPANESE_PRETRAINED_MODEL_ARCHIVE_LIST,
          GPTNeoXJapaneseForCausalLM,
          GPTNeoXJapaneseLayer,
          GPTNeoXJapaneseModel,
          GPTNeoXJapanesePreTrainedModel,
      )


else:
   import sys

   UpperCAmelCase__						:Tuple          =			_LazyModule(__name__, globals()["""__file__"""], _import_structure, module_spec=__spec__)











'''simple docstring'''

from __future__ import annotations

from typing import Any
def     __lowercase  (_lowercase     )   ->     int:


     """simple docstring"""
     if not postfix_notation:
          return 0

     __lowerCamelCase						:       Optional[int]				   =				{"""+""", """-""", """*""", """/"""}
     __lowerCamelCase						:       list[Any]				   =				[]

     for token in postfix_notation:
          if token in operations:
               __lowerCamelCase   ,      __lowerCamelCase						:       List[Any]				   =				stack.pop(), stack.pop()
               if token == "+":
                    stack.append(a + b     )
               elif token == "-":
                    stack.append(a - b     )
               elif token == "*":
                    stack.append(a * b     )
               else:
                    if a * b < 0 and a % b != 0:
                         stack.append(a // b + 1     )
                    else:
                         stack.append(a // b     )
          else:
               stack.append(int(_lowercase     )     )

     return stack.pop()


if __name__ == "__main__":
   import doctest

   doctest.testmod()



