code: 
  """simple docstring"""
  import unittest
  
  from cer import CER
  
  
  __magic_name__		       =				CER()
  
  
  class    _lowerCAmelCase						(						unittest.TestCase						):
  
  
  
  							def       _a   (      self   )							->							Optional[Any]:
  								_UpperCAmelCase =						["White House"]
  								_UpperCAmelCase =						["white house"]
  								# S = 2, D = 0, I = 0, N = 11, CER = 2 / 11
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.1818181818   ) < 1e-6   )
  
  
  
  							def       _a   (      self   )							->							int:
  								_UpperCAmelCase =						["were wolf"]
  								_UpperCAmelCase =						["werewolf"]
  								# S = 0, D = 0, I = 1, N = 9, CER = 1 / 9
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.1111111   ) < 1e-6   )
  
  								_UpperCAmelCase =						["werewolf"]
  								_UpperCAmelCase =						["weae     wolf"]
  								# S = 1, D = 1, I = 0, N = 8, CER = 0.25
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.25   ) < 1e-6   )
  
  								# consecutive whitespaces case 1
  								_UpperCAmelCase =						["were wolf"]
  								_UpperCAmelCase =						["were               wolf"]
  								# S = 0, D = 0, I = 0, N = 9, CER = 0
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.0   ) < 1e-6   )
  
  								# consecutive whitespaces case 2
  								_UpperCAmelCase =						["were   wolf"]
  								_UpperCAmelCase =						["were               wolf"]
  								# S = 0, D = 0, I = 0, N = 9, CER = 0
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.0   ) < 1e-6   )
  
  
  
  							def       _a   (      self   )							->							List[Any]:
  								_UpperCAmelCase =						["werewolf"]
  								_UpperCAmelCase =						["weaewolf"]
  								# S = 1, D = 0, I = 0, N = 8, CER = 0.125
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.125   ) < 1e-6   )
  
  
  
  							def       _a   (      self   )							->							List[Any]:
  								_UpperCAmelCase =						["werewolf"]
  								_UpperCAmelCase =						["wereawolf"]
  								# S = 0, D = 1, I = 0, N = 8, CER = 0.125
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.125   ) < 1e-6   )
  
  
  
  							def       _a   (      self   )							->							Optional[int]:
  								_UpperCAmelCase =						["werewolf"]
  								_UpperCAmelCase =						["wereolf"]
  								# S = 0, D = 0, I = 1, N = 8, CER = 0.125
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.125   ) < 1e-6   )
  
  
  
  							def       _a   (      self   )							->							Optional[int]:
  								_UpperCAmelCase =						["werewolf"]
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertEqual(a_ ,						0.0   )
  
  
  
  							def       _a   (      self   )							->							List[str]:
  								_UpperCAmelCase =						["werewolf", "I am your father"]
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertEqual(a_ ,						0.0   )
  
  								_UpperCAmelCase =						["werewolf", "I am your father", "doge"]
  								_UpperCAmelCase =						["werxwolf", "I       am your father", "doge"]
  								# S = 1, D = 0, I = 0, N = 28, CER = 1 / 28
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.03571428   ) < 1e-6   )
  
  
  
  							def       _a   (      self   )							->							List[Any]:
  								_UpperCAmelCase =						["My hovercraft", "is full of eels"]
  								_UpperCAmelCase =						["My hovercraft is full", " of eels"]
  								# S = 0, D = 0, I = 2, N = 28, CER = 2 / 28
  								# whitespace at the front of " of eels" will be strip during preporcessing
  								# so need to insert 2 whitespaces
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_ ,						concatenate_texts=a_   )
  								self.assertTrue(abs(char_error_rate - 0.071428   ) < 1e-6   )
  
  
  
  							def       _a   (      self   )							->							Optional[int]:
  								_UpperCAmelCase =						["我能吞下玻璃而不伤身体"]
  								_UpperCAmelCase =						[" 能吞虾玻璃而 不霜身体啦"]
  								# S = 3, D = 2, I = 0, N = 11, CER = 5 / 11
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.4545454545   ) < 1e-6   )
  
  								_UpperCAmelCase =						["我能吞下玻璃", "而不伤身体"]
  								_UpperCAmelCase =						["我    能 吞 下 玻 璃", "而不伤身体"]
  								# S = 0, D = 5, I = 0, N = 11, CER = 5 / 11
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertTrue(abs(char_error_rate - 0.454545454545   ) < 1e-6   )
  
  								_UpperCAmelCase =						["我能吞下玻璃而不伤身体"]
  								_UpperCAmelCase =						cer.compute(predictions=a_ ,						references=a_   )
  								self.assertFalse(a_ ,						0.0   )
  
  
  
  							def       _a   (      self   )							->							Dict:
  								_UpperCAmelCase =						[""]
  								_UpperCAmelCase =						["Hypothesis"]
  								with self.assertRaises(a_   ):
  									cer.compute(predictions=a_ ,						references=a_   )
  
  
  if __name__ == "__main__":
  			unittest.main()
  
  
  
  
  
style_context: 
  """simple docstring"""
  def     __lowerCamelCase  (		UpperCamelCase__      ):
  
  
  	"""simple docstring"""
  
  
  
  
  
  
  	if not isinstance(UpperCamelCase__				,     UpperCamelCase__      ):
  		raise TypeError("recursive_lucas_number accepts only integer arguments."      )
  	if n_th_number == 0:
  		return 2
  	if n_th_number == 1:
  		return 1
  
  	return recursive_lucas_number(n_th_number - 1      ) + recursive_lucas_number(
  	    n_th_number - 2      )
  
  
  
  
  def     __lowerCamelCase  (		UpperCamelCase__      ):
  
  
  	"""simple docstring"""
  
  
  
  
  
  
  	if not isinstance(UpperCamelCase__				,     UpperCamelCase__      ):
  		raise TypeError("dynamic_lucas_number accepts only integer arguments."      )
  	_UpperCAmelCase ,      _UpperCAmelCase =						2, 1
  	for _ in range(UpperCamelCase__      ):
  		_UpperCAmelCase ,      _UpperCAmelCase =						b, a + b
  	return a
  
  
  if __name__ == "__main__":
  			from doctest import testmod
  
  			testmod()
  			__magic_name__		       =				int(input('''Enter the number of terms in lucas series:\n''').strip())
  			print('''Using recursive function to calculate lucas series:''')
  			print(''' '''.join(str(recursive_lucas_number(i)) for i in range(n)))
  			print('''\nUsing dynamic function to calculate lucas series:''')
  			print(''' '''.join(str(dynamic_lucas_number(i)) for i in range(n)))
  
  
  
  
  