





'''simple docstring'''




import enum
import shutil
import sys


__UpperCAmelCase       ,      __UpperCAmelCase            =       shutil.get_terminal_size()

__UpperCAmelCase            =       {"""UP""": """A""", """DOWN""": """B""", """RIGHT""": """C""", """LEFT""": """D"""}




class      UpperCamelCase__					(					enum.Enum			):




					"""simple docstring"""
					SCREAMING_SNAKE_CASE__				=	0
					SCREAMING_SNAKE_CASE__				=	1







def 		__A		(  lowerCamelCase_			,			lowerCamelCase_=""	):


		"""simple docstring"""



		sys.stdout.write(str(lowerCamelCase_	) + end	)
		sys.stdout.flush()



def 		__A		(  lowerCamelCase_			,			lowerCamelCase_			,			lowerCamelCase_=""	):


		"""simple docstring"""



		forceWrite(f'''\u001b[{color}m{content}\u001b[0m'''			,			lowerCamelCase_	)



def 		__A		(  ):


		"""simple docstring"""



		forceWrite("""\r"""	)



def 		__A		(  lowerCamelCase_			,			lowerCamelCase_	):


		"""simple docstring"""



		forceWrite(f'''\033[{num_lines}{CURSOR_TO_CHAR[direction.upper()]}'''	)



def 		__A		(  ):


		"""simple docstring"""



		forceWrite(""" """ * TERMINAL_WIDTH	)
		reset_cursor()



def 		__A		(  ):


		"""simple docstring"""



		reset_cursor()
		forceWrite("""-""" * TERMINAL_WIDTH	)










'''simple docstring'''




from __future__ import annotations



def 		__A		(  lowerCamelCase_			,			lowerCamelCase_	):


		"""simple docstring"""



		if partitions <= 0:
				raise ValueError("""partitions must be a positive number!"""	)
		if partitions > number_of_bytes:
				raise ValueError("""partitions can not > number_of_bytes!"""	)
		SCREAMING_SNAKE_CASE :				int		=			number_of_bytes // partitions
		SCREAMING_SNAKE_CASE :				int		=			[]
		for i in range(lowerCamelCase_	):
				SCREAMING_SNAKE_CASE :				Optional[Any]		=			i * bytes_per_partition + 1
				SCREAMING_SNAKE_CASE :				Optional[int]		=			(
				    number_of_bytes if i == partitions - 1 else (i + 1) * bytes_per_partition
				)
				allocation_list.append(f'''{start_bytes}-{end_bytes}'''	)
		return allocation_list


if __name__ == "__main__":
							import doctest

							doctest.testmod()



