class_docstr: A class representing a modular integer. 
class_docstr_tok: ["A","class","representing","a","modular","integer","."]
code: def __pow__(self, exp):
      if not exp:
          return self.__class__(self.dom.one)
  
      if exp < 0:
          val, exp = self.invert().val, -exp
      else:
          val = self.val
  
      return self.__class__(pow(val, int(exp), self.mod))
  
imports: from __future__ import annotations
  from typing import Any
  import operator
  from sympy.polys.polyutils import PicklableWithSlots
  from sympy.polys.polyerrors import CoercionFailed
  from sympy.polys.domains.domainelement import DomainElement
  from sympy.utilities import public
  from sympy.utilities.exceptions import sympy_deprecation_warning
label_desc: Use image node_id 21 for calling the ModularInteger obj's underlying member method code with example usage: obj.__pow__(exp) and returns: self, self