

"""simple docstring"""


from urllib.parse import quote

import pytest

from datasets.utils.hub import hf_hub_url






@pytest.mark.parametrize("repo_id" ,			["canonical_dataset_name", "org-name/dataset-name"]			)
@pytest.mark.parametrize("path" ,			["filename.csv", "filename with blanks.csv"]			)
@pytest.mark.parametrize("revision" ,			[None, "v2"]			)
def    a__   (   __SCREAMING_SNAKE_CASE ,			__SCREAMING_SNAKE_CASE ,			__SCREAMING_SNAKE_CASE			)     ->     List[Any]:
		__lowerCAmelCase:	Union[str, Any]   				=      hf_hub_url(repo_id=__SCREAMING_SNAKE_CASE ,			path=__SCREAMING_SNAKE_CASE ,			revision=__SCREAMING_SNAKE_CASE			)
		assert url == F"https://huggingface.co/datasets/{repo_id}/resolve/{revision or 'main'}/{quote(__SCREAMING_SNAKE_CASE			)}"





"""simple docstring"""


import math
import sys






def    a__   (   __SCREAMING_SNAKE_CASE			)     ->     int:
		if number != int(__SCREAMING_SNAKE_CASE			):
				raise ValueError("the value of input must be a natural number"			)
		if number < 0:
				raise ValueError("the value of input must not be a negative number"			)
		if number == 0:
				return 1
		__lowerCAmelCase:	int   				=      [-1] * (number + 1)
		__lowerCAmelCase:	Optional[Any]   				=      0
		for i in range(1 ,			number + 1			):
				__lowerCAmelCase:	List[str]   				=      sys.maxsize
				__lowerCAmelCase:	int   				=      int(math.sqrt(__SCREAMING_SNAKE_CASE			)			)
				for j in range(1 ,			root + 1			):
						__lowerCAmelCase:	Optional[Any]   				=      1 + answers[i - (j**2)]
						__lowerCAmelCase:	List[Any]   				=      min(__SCREAMING_SNAKE_CASE ,			__SCREAMING_SNAKE_CASE			)
				__lowerCAmelCase:	Optional[Any]   				=      answer
		return answers[number]


if __name__ == "__main__":
			import doctest

			doctest.testmod()


