






"""simple docstring"""
from __future__ import annotations

from typing import Generic, TypeVar

A_     :					Any							=     TypeVar("T")



class 						a_ (      snake_case_					):







      '''simple docstring'''

      pass



class 						a_ (      snake_case_					):







      '''simple docstring'''

      pass



class 						a_ (      Generic[T]					):







      '''simple docstring'''

      def __init__(self,	lowerCamelCase_ = 1_0   ):

       '''simple docstring'''



       lowerCamelCase__	:     list[T]								=		[]
       lowerCamelCase__	:     List[str]								=		limit




      def __bool__(self   ):

       '''simple docstring'''



       return bool(self.stack   )




      def __str__(self   ):

       '''simple docstring'''



       return str(self.stack   )




      def      a__				(self,	lowerCamelCase_   ):

       '''simple docstring'''



       if len(self.stack   ) >= self.limit:
        raise StackOverflowError
       self.stack.append(lowerCamelCase_   )




      def      a__				(self   ):

       '''simple docstring'''



       if not self.stack:
        raise StackUnderflowError
       return self.stack.pop()




      def      a__				(self   ):

       '''simple docstring'''



       if not self.stack:
        raise StackUnderflowError
       return self.stack[-1]




      def      a__				(self   ):

       '''simple docstring'''



       return not bool(self.stack   )




      def      a__				(self   ):

       '''simple docstring'''



       return self.size() == self.limit




      def      a__				(self   ):

       '''simple docstring'''



       return len(self.stack   )





      def __contains__(self,	lowerCamelCase_   ):

       '''simple docstring'''



       return item in self.stack






def 			lowerCamelCase_    (		):
 lowerCamelCase__	:     Stack[int]								=		Stack(10							)
 assert bool(_lowerCamelCase							) is False
 assert stack.is_empty() is True
 assert stack.is_full() is False
 assert str(_lowerCamelCase							) == "[]"

 try:
  lowerCamelCase__	:     Optional[Any]								=		stack.pop()
  raise AssertionError  # This should not happen
 except StackUnderflowError:
  assert True  # This should happen

 try:
  lowerCamelCase__	:     int								=		stack.peek()
  raise AssertionError  # This should not happen
 except StackUnderflowError:
  assert True  # This should happen

 for i in range(10							):
  assert stack.size() == i
  stack.push(_lowerCamelCase							)

 assert bool(_lowerCamelCase							)
 assert not stack.is_empty()
 assert stack.is_full()
 assert str(_lowerCamelCase							) == str(list(range(10							)							)							)
 assert stack.pop() == 9
 assert stack.peek() == 8

 stack.push(100							)
 assert str(_lowerCamelCase							) == str([0, 1, 2, 3, 4, 5, 6, 7, 8, 100]							)

 try:
  stack.push(200							)
  raise AssertionError  # This should not happen
 except StackOverflowError:
  assert True  # This should happen

 assert not stack.is_empty()
 assert stack.size() == 10

 assert 5 in stack
 assert 55 not in stack


if __name__ == "__main__":
      test_stack()









"""simple docstring"""
from itertools import combinations, product






def 			lowerCamelCase_    (		_lowerCamelCase     ,  _lowerCamelCase     ,  _lowerCamelCase     ,  _lowerCamelCase							):
 if xa == ya == 0 or xa == ya == 0:
  return False
 lowerCamelCase__	:     Tuple								=		xa * xa + ya * ya
 lowerCamelCase__	:     Union[str, Any]								=		xa * xa + ya * ya
 lowerCamelCase__	:     Optional[Any]								=		(xa - xa) * (xa - xa) + (ya - ya) * (ya - ya)
 return (
     a_square + b_square == c_square
     or a_square + c_square == b_square
     or b_square + c_square == a_square
 )






def 			lowerCamelCase_    (		_lowerCamelCase = 50							):
 return sum(
     1
     for pta, pta in combinations(product(range(limit + 1							)     ,  repeat=2							)     ,  2							)
     if is_right(*_lowerCamelCase     ,  *_lowerCamelCase							)							)


if __name__ == "__main__":
      print(f"{solution() = }")

