code: from __future__ import annotations
  
  
  
  
  
  
  def   __lowerCamelCase	(       lowerCamelCase__		:	Tuple     ,       lowerCamelCase__		:	Tuple     ,       lowerCamelCase__		:	Optional[Any]			):
  
  
  
  
  
  			'''simple docstring'''
  
  
  
  
  			assert (
  			    c % greatest_common_divisor(SCREAMING_SNAKE_CASE__     ,       SCREAMING_SNAKE_CASE__			) == 0
  			)  # greatest_common_divisor(a,b) function implemented below
  			(lowerCamelCase)								=     extended_gcd(SCREAMING_SNAKE_CASE__     ,       SCREAMING_SNAKE_CASE__			)  # extended_gcd(a,b) function implemented below
  			lowerCamelCase								=     c / d
  			return (r * x, r * y)
  
  
  
  
  
  
  def   __lowerCamelCase	(       lowerCamelCase__		:	Any     ,       lowerCamelCase__		:	Dict     ,       lowerCamelCase__		:	Any     ,       lowerCamelCase__		:	Union[str, Any] = 2			):
  
  
  
  
  
  			'''simple docstring'''
  
  
  
  
  			(lowerCamelCase)								=     diophantine(SCREAMING_SNAKE_CASE__     ,       SCREAMING_SNAKE_CASE__     ,       SCREAMING_SNAKE_CASE__			)  # Initial value
  			lowerCamelCase								=     greatest_common_divisor(SCREAMING_SNAKE_CASE__     ,       SCREAMING_SNAKE_CASE__			)
  			lowerCamelCase								=     a // d
  			lowerCamelCase								=     b // d
  
  			for i in range(SCREAMING_SNAKE_CASE__			):
  						lowerCamelCase								=     xa + i * q
  						lowerCamelCase								=     ya - i * p
  						print(SCREAMING_SNAKE_CASE__     ,       SCREAMING_SNAKE_CASE__			)
  
  
  
  
  
  
  def   __lowerCamelCase	(       lowerCamelCase__		:	Dict     ,       lowerCamelCase__		:	Tuple			):
  
  
  
  
  
  			'''simple docstring'''
  
  
  
  
  			if a < b:
  						lowerCamelCase								=     b, a
  
  			while a % b != 0:
  						lowerCamelCase								=     b, a % b
  
  			return b
  
  
  
  
  
  
  def   __lowerCamelCase	(       lowerCamelCase__		:	List[str]     ,       lowerCamelCase__		:	Optional[int]			):
  
  
  
  
  
  			'''simple docstring'''
  
  
  
  
  			assert a >= 0 and b >= 0
  
  			if b == 0:
  						lowerCamelCase								=     a, 1, 0
  			else:
  						(lowerCamelCase)								=     extended_gcd(SCREAMING_SNAKE_CASE__     ,       a % b			)
  						lowerCamelCase								=     q
  						lowerCamelCase								=     p - q * (a // b)
  
  			assert a % d == 0 and b % d == 0
  			assert d == a * x + b * y
  
  			return (d, x, y)
  
  
  if __name__ == "__main__":
  		from doctest import testmod
  
  		testmod(name="diophantine", verbose=True)
  		testmod(name="diophantine_all_soln", verbose=True)
  		testmod(name="extended_gcd", verbose=True)
  		testmod(name="greatest_common_divisor", verbose=True)
  
  
style_context: 
  
  
  import abc
  import copy
  import dataclasses
  from dataclasses import dataclass
  from typing import ClassVar, Dict, Type, TypeVar
  
  from ..features import Features
  
  
  UpperCAmelCase      :						List[Any]    =		TypeVar("T", bound="TaskTemplate")
  
  
  
  
  
  
  
  @dataclass(frozen=a_     )
  class 					__lowercase					(       abc.ABC     ):
  
  
  
  		"""simple docstring"""
  
  		UpperCamelCase    :				str
  		UpperCamelCase    :				ClassVar[Features]
  		UpperCamelCase    :				ClassVar[Features]
  
  
  
  
  
  
  
  		def 				__A      (   self		,			A  )     ->   T:
  
  
  
  
  
  
  
  					'''simple docstring'''
  
  
  
  
  
  
  
  					return copy.deepcopy(self  )
  
  
  
  
  
  
  
  		@property
  		def 				__A      (   self  )     ->   Features:
  
  
  
  
  
  
  
  					'''simple docstring'''
  
  
  
  
  
  
  
  					return Features(**self.input_schema		,			**self.label_schema  )
  
  
  
  
  
  
  
  		@property
  		@abc.abstractmethod
  		def 				__A      (   self  )     ->   Dict[str, str]:
  
  
  
  
  
  
  
  					'''simple docstring'''
  
  
  
  
  
  
  
  					raise NotImplementedError
  
  
  
  
  
  
  
  		@classmethod
  		def 				__A      (   cls		,			A  )     ->   T:
  
  
  
  
  
  
  
  					'''simple docstring'''
  
  
  
  
  
  
  
  					lowerCamelCase								=     {f.name for f in dataclasses.fields(cls  )}
  					return cls(**{k: v for k, v in template_dict.items() if k in field_names}  )
  
  