


'''simple docstring'''



import dataclasses
import re
from dataclasses import dataclass
from functools import total_ordering
from typing import Optional, Union


lowerCAmelCase	:		List[str]				=   re.compile(r'''^(?P<major>\d+)''' r'''\.(?P<minor>\d+)''' r'''\.(?P<patch>\d+)$''')






@total_ordering
@dataclass
class 					UpperCAmelCase__	:
					a      :     str
					a      :     Optional[str]        =							None
					a      :     Optional[Union[str, int]]        =							None
					a      :     Optional[Union[str, int]]        =							None
					a      :     Optional[Union[str, int]]        =							None



					def        UpperCAmelCase_ (    self     )     ->			str:
						__lowerCAmelCase							,       __lowerCAmelCase							,       __lowerCAmelCase												=  _str_to_version_tuple(self.version_str     )



					def __repr__(    self     )     ->			Optional[Any]:
						return F'''{self.tuple[0]}.{self.tuple[1]}.{self.tuple[2]}'''



					@property
					def        UpperCAmelCase_ (    self     )     ->			Union[str, Any]:
						return self.major, self.minor, self.patch



					def        UpperCAmelCase_ (    self			,				UpperCamelCase     )     ->			Dict:

						if isinstance(UpperCamelCase			,				UpperCamelCase     ):
							return Version(UpperCamelCase     )
						elif isinstance(UpperCamelCase			,				UpperCamelCase     ):
							return other
						raise TypeError(F'''{other} (type {type(UpperCamelCase     )}) cannot be compared to version.'''     )



					def __eq__(    self			,				UpperCamelCase     )     ->			int:

						try:
							__lowerCAmelCase												=  self._validate_operand(UpperCamelCase     )
						except (TypeError, ValueError):
							return False
						else:
							return self.tuple == other.tuple



					def __lt__(    self			,				UpperCamelCase     )     ->			List[str]:
						__lowerCAmelCase												=  self._validate_operand(UpperCamelCase     )
						return self.tuple < other.tuple



					def __hash__(    self     )     ->			List[str]:
						return hash(_version_tuple_to_str(self.tuple     )     )



					@classmethod
					def        UpperCAmelCase_ (    cls			,				UpperCamelCase     )     ->			str:
						__lowerCAmelCase												=  {f.name for f in dataclasses.fields(cls     )}
						return cls(**{k: v for k, v in dic.items() if k in field_names}     )



					def        UpperCAmelCase_ (    self     )     ->			Optional[Any]:
						return self.version_str



def   __lowerCAmelCase					(							lowerCamelCase   :						Dict					):






	'''simple docstring'''




	__lowerCAmelCase												=  _VERSION_REG.match(_UpperCamelCase					)
	if not res:
		raise ValueError(f'''Invalid version \'{version_str}\'. Format should be x.y.z with {{x,y,z}} being digits.'''					)
	return tuple(int(_UpperCamelCase					) for v in [res.group("major"					), res.group("minor"					), res.group("patch"					)]					)




def   __lowerCAmelCase					(							lowerCamelCase   :						Any					):






	'''simple docstring'''




	return ".".join(str(_UpperCamelCase					) for v in version_tuple					)




'''simple docstring'''



import re



def   __lowerCAmelCase					(							lowerCamelCase   :						str					):






	'''simple docstring'''




	__lowerCAmelCase												=  re.compile(
	    r"^(?:0|94|\+94|0{2}94)" r"7(0|1|2|4|5|6|7|8)" r"(-| |)" r"\d{7}$"					)

	return bool(re.search(lowerCamelCase				,		lowerCamelCase					)					)


if __name__ == "__main__":
	lowerCAmelCase	:		Optional[Any]				=   '''0094702343221'''

	print(is_sri_lankan_phone_number(phone))