from __future__ import annotations

import typing
from collections import Counter

def    SCREAMING_SNAKE_CASE_     (						snake_case__							)     ->	Any:
							lowerCAmelCase			=		Counter()
							for base in range(1   ,  max_perimeter + 1							):
														for perpendicular in range(snake_case__   ,  max_perimeter + 1							):
																					lowerCAmelCase			=		(base * base + perpendicular * perpendicular) ** 0.5
																					if hypotenuse == int(snake_case__							):
																												lowerCAmelCase			=		int(base + perpendicular + hypotenuse							)
																												if perimeter > max_perimeter:
																																			continue
																												triplets[perimeter] += 1
							return triplets

def    SCREAMING_SNAKE_CASE_     (						snake_case__ = 1_0_0_0							)     ->	List[Any]:
							lowerCAmelCase			=		pythagorean_triple(snake_case__							)
							return triplets.most_common(1							)[0][0]


if __name__ == "__main__":
	print(f'Perimeter {solution()} has maximum solutions')





'''simple docstring'''




import pytest

import datasets.config
from datasets.utils.info_utils import is_small_dataset







@pytest.mark.parametrize('''dataset_size'''		,				[None, 400 * 2**20, 600 * 2**20]						)
@pytest.mark.parametrize('''input_in_memory_max_size'''		,				['''default''', 0, 100 * 2**20, 900 * 2**20]						)
def 		lowerCAmelCase_				(   snake_case__		,				snake_case__		,				snake_case__						):




    '''simple docstring'''



    if input_in_memory_max_size != "default":
        monkeypatch.setattr(datasets.config		,				'''IN_MEMORY_MAX_SIZE'''		,				snake_case__						)
    A       :   Dict					=						datasets.config.IN_MEMORY_MAX_SIZE
    if input_in_memory_max_size == "default":
        assert in_memory_max_size == 0
    else:
        assert in_memory_max_size == input_in_memory_max_size
    if dataset_size and in_memory_max_size:
        A       :   Dict					=						dataset_size < in_memory_max_size
    else:
        A       :   Tuple					=						False
    A       :   int					=						is_small_dataset(snake_case__						)
    assert result == expected




