code: '''simple docstring'''
  
  
  
  
  
  import os
  
  from ...utils import logging
  from .utils import DataProcessor, InputExample
  
  
  lowercase__    :       List[str]						=			logging.get_logger(__name__)
  
  
  
  
  class      lowercase_						(						lowerCamelCase__		):
  
  
  
  	"""simple docstring"""
  
  
  
  
  
  	def __init__(							self	,    __SCREAMING_SNAKE_CASE	,    __SCREAMING_SNAKE_CASE=None       )		->List[Any]:
  								lowerCAmelCase				=	language
  								lowerCAmelCase				=	train_language
  
  
  	def     SCREAMING_SNAKE_CASE_       (							self	,    __SCREAMING_SNAKE_CASE       )		->List[Any]:
  								lowerCAmelCase				=	self.language if self.train_language is None else self.train_language
  								lowerCAmelCase				=	self._read_tsv(os.path.join(lowercase_	,    F"XNLI-MT-1.0/multinli/multinli.train.{lg}.tsv"       )       )
  								lowerCAmelCase				=	[]
  								for i, line in enumerate(lowercase_       ):
  															if i == 0:
  																						continue
  															lowerCAmelCase				=	F"train-{i}"
  															lowerCAmelCase				=	line[0]
  															lowerCAmelCase				=	line[1]
  															lowerCAmelCase				=	'''contradiction''' if line[2] == '''contradictory''' else line[2]
  															if not isinstance(lowercase_	,    lowercase_       ):
  																						raise ValueError(F"Training input {text_a} is not a string"       )
  															if not isinstance(lowercase_	,    lowercase_       ):
  																						raise ValueError(F"Training input {text_b} is not a string"       )
  															if not isinstance(lowercase_	,    lowercase_       ):
  																						raise ValueError(F"Training label {label} is not a string"       )
  															examples.append(InputExample(guid=lowercase_	,    text_a=lowercase_	,    text_b=lowercase_	,    label=lowercase_       )       )
  								return examples
  
  
  	def     SCREAMING_SNAKE_CASE_       (							self	,    __SCREAMING_SNAKE_CASE       )		->Any:
  								lowerCAmelCase				=	self._read_tsv(os.path.join(lowercase_	,    '''XNLI-1.0/xnli.test.tsv'''       )       )
  								lowerCAmelCase				=	[]
  								for i, line in enumerate(lowercase_       ):
  															if i == 0:
  																						continue
  															lowerCAmelCase				=	line[0]
  															if language != self.language:
  																						continue
  															lowerCAmelCase				=	F"test-{i}"
  															lowerCAmelCase				=	line[6]
  															lowerCAmelCase				=	line[7]
  															lowerCAmelCase				=	line[1]
  															if not isinstance(lowercase_	,    lowercase_       ):
  																						raise ValueError(F"Training input {text_a} is not a string"       )
  															if not isinstance(lowercase_	,    lowercase_       ):
  																						raise ValueError(F"Training input {text_b} is not a string"       )
  															if not isinstance(lowercase_	,    lowercase_       ):
  																						raise ValueError(F"Training label {label} is not a string"       )
  															examples.append(InputExample(guid=lowercase_	,    text_a=lowercase_	,    text_b=lowercase_	,    label=lowercase_       )       )
  								return examples
  
  
  
  
  	def     SCREAMING_SNAKE_CASE_       (							self       )		->Dict:
  								return ["contradiction", "entailment", "neutral"]
  lowercase__    :       Tuple						=			{
      '''xnli''': XnliProcessor,
  }
  
  lowercase__    :       List[Any]						=			{
      '''xnli''': '''classification''',
  }
  
  lowercase__    :       Optional[Any]						=			{
      '''xnli''': 3,
  }
  
  
  
  
style_context: def      SCREAMING_SNAKE_CASE_  (		snake_case__     ,						snake_case__							)  ->			int:
  							return (input_a, input_a).count(0							) % 2
  
  def      SCREAMING_SNAKE_CASE_  (		)  ->			None:
  							assert xor_gate(0     ,						0							) == 0
  							assert xor_gate(0     ,						1							) == 1
  							assert xor_gate(1     ,						0							) == 1
  							assert xor_gate(1     ,						1							) == 0
  
  
  if __name__ == "__main__":
  	print(xor_gate(0, 0))
  	print(xor_gate(0, 1))
  
  
  
  