






from typing import TYPE_CHECKING

from ...utils import (
    OptionalDependencyNotAvailable,
    _LazyModule,
    is_flax_available,
    is_tf_available,
    is_tokenizers_available,
    is_torch_available,
)


__a					:				Optional[int]      =      {
    "configuration_mpnet": ["MPNET_PRETRAINED_CONFIG_ARCHIVE_MAP", "MPNetConfig"],
    "tokenization_mpnet": ["MPNetTokenizer"],
}

try:
  if not is_tokenizers_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  __a					:				List[str]      =      ["MPNetTokenizerFast"]

try:
  if not is_torch_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  __a					:				Optional[Any]      =      [
      "MPNET_PRETRAINED_MODEL_ARCHIVE_LIST",
      "MPNetForMaskedLM",
      "MPNetForMultipleChoice",
      "MPNetForQuestionAnswering",
      "MPNetForSequenceClassification",
      "MPNetForTokenClassification",
      "MPNetLayer",
      "MPNetModel",
      "MPNetPreTrainedModel",
  ]

try:
  if not is_tf_available():
    raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
  pass
else:
  __a					:				List[Any]      =      [
      "TF_MPNET_PRETRAINED_MODEL_ARCHIVE_LIST",
      "TFMPNetEmbeddings",
      "TFMPNetForMaskedLM",
      "TFMPNetForMultipleChoice",
      "TFMPNetForQuestionAnswering",
      "TFMPNetForSequenceClassification",
      "TFMPNetForTokenClassification",
      "TFMPNetMainLayer",
      "TFMPNetModel",
      "TFMPNetPreTrainedModel",
  ]


if TYPE_CHECKING:
  from .configuration_mpnet import MPNET_PRETRAINED_CONFIG_ARCHIVE_MAP, MPNetConfig
  from .tokenization_mpnet import MPNetTokenizer

  try:
    if not is_tokenizers_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .tokenization_mpnet_fast import MPNetTokenizerFast

  try:
    if not is_torch_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .modeling_mpnet import (
        MPNET_PRETRAINED_MODEL_ARCHIVE_LIST,
        MPNetForMaskedLM,
        MPNetForMultipleChoice,
        MPNetForQuestionAnswering,
        MPNetForSequenceClassification,
        MPNetForTokenClassification,
        MPNetLayer,
        MPNetModel,
        MPNetPreTrainedModel,
    )

  try:
    if not is_tf_available():
      raise OptionalDependencyNotAvailable()
  except OptionalDependencyNotAvailable:
    pass
  else:
    from .modeling_tf_mpnet import (
        TF_MPNET_PRETRAINED_MODEL_ARCHIVE_LIST,
        TFMPNetEmbeddings,
        TFMPNetForMaskedLM,
        TFMPNetForMultipleChoice,
        TFMPNetForQuestionAnswering,
        TFMPNetForSequenceClassification,
        TFMPNetForTokenClassification,
        TFMPNetMainLayer,
        TFMPNetModel,
        TFMPNetPreTrainedModel,
    )

else:
  import sys

  __a					:				Dict      =      _LazyModule(__name__, globals()["__file__"], _import_structure, module_spec=__spec__)









from __future__ import annotations



def        __a     (    lowerCAmelCase_   :					int				)      -> int | None:






						'''simple docstring'''



						for r in range(1			,lowerCAmelCase_				):
												UpperCAmelCase_=   []
												for x in range(n - 1				):
																		UpperCAmelCase_=   pow(lowerCAmelCase_			,lowerCAmelCase_			,lowerCAmelCase_				)
																		if val in li:
																								break
																		li.append(lowerCAmelCase_				)
												else:
																		return r
						return None


if __name__ == "__main__":
	__A				    =						int(input('''Enter a prime number q: '''))
	__A				    =						find_primitive(q)
	if a is None:
		print(f'Cannot find the primitive for the value: {a!r}')
	else:
		__A				    =						int(input('''Enter private key of A: '''))
		__A				    =						pow(a, a_private, q)
		__A				    =						int(input('''Enter private key of B: '''))
		__A				    =						pow(a, b_private, q)

		__A				    =						pow(b_public, a_private, q)
		__A				    =						pow(a_public, b_private, q)

		print('''The key value generated by A is: ''', a_secret)
		print('''The key value generated by B is: ''', b_secret)




