


import os
from collections.abc import Iterator







def     lowerCAmelCase_					( __lowerCamelCase = "."     ):
							for dir_path, dir_names, filenames in os.walk(__lowerCamelCase     ):
														__snake_case		:      Optional[int]										=       [d for d in dir_names if d != "scripts" and d[0] not in "._"]
														for filename in filenames:
																					if filename == "__init__.py":
																												continue
																					if os.path.splitext(__lowerCamelCase     )[1] in (".py", ".ipynb"):
																												yield os.path.join(__lowerCamelCase							,     __lowerCamelCase     ).lstrip("./"     )







def     lowerCAmelCase_					( __lowerCamelCase     ):
							return F'{i * "  "}*' if i else "\n##"







def     lowerCAmelCase_					( __lowerCamelCase							,     __lowerCamelCase     ):
							__snake_case		:      List[Any]										=       old_path.split(os.sep     )
							for i, new_part in enumerate(new_path.split(os.sep     )     ):
														if (i + 1 > len(__lowerCamelCase     ) or old_parts[i] != new_part) and new_part:
																					print(F'{md_prefix(__lowerCamelCase     )} {new_part.replace("_"							,     " "     ).title()}'     )
							return new_path







def     lowerCAmelCase_					( __lowerCamelCase = "."     ):
							__snake_case		:      List[str]										=       ""
							for filepath in sorted(good_file_paths(__lowerCamelCase     )     ):
														__snake_case			,      __snake_case		:      List[Any]										=       os.path.split(__lowerCamelCase     )
														if filepath != old_path:
																					__snake_case		:      int										=       print_path(__lowerCamelCase							,     __lowerCamelCase     )
														__snake_case		:      Union[str, Any]										=       (filepath.count(os.sep     ) + 1) if filepath else 0
														__snake_case		:      str										=       F'{filepath}/{filename}'.replace(" "							,     "%20"     )
														__snake_case		:      List[Any]										=       os.path.splitext(filename.replace("_"							,     " "     ).title()     )[0]
														print(F'{md_prefix(__lowerCamelCase     )} [{filename}]({url})'     )


if __name__ == "__main__":
			print_directory_md(".")





def     lowerCAmelCase_					( __lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase     ):
							if index == r:
														for j in range(__lowerCamelCase     ):
																					print(data[j]							,     end=" "     )
														print(" "     )
														return
							#  When no more elements are there to put in data[]
							if i >= n:
														return
							# current is included, put next at next location
							__snake_case		:      Union[str, Any]										=       arr[i]
							combination_util(__lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     index + 1							,     __lowerCamelCase							,     i + 1     )
							# current is excluded, replace it with
							# next (Note that i+1 is passed, but
							# index is not changed)
							combination_util(__lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     i + 1     )
							# The main function that prints all combinations
							# of size r in arr[] of size n. This function
							# mainly uses combinationUtil()







def     lowerCAmelCase_					( __lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase     ):
							# A temporary array to store all combination one by one
							__snake_case		:      Union[str, Any]										=       [0] * r
							# Print all combination using temporary array 'data[]'
							combination_util(__lowerCamelCase							,     __lowerCamelCase							,     __lowerCamelCase							,     0							,     __lowerCamelCase							,     0     )


if __name__ == "__main__":
			# Driver code to check the function above
			_snake_case					:		List[str]      =    [10, 20, 30, 40, 50]
			print_combination(arr, len(arr), 3)
			# This code is contributed by Ambuj sahu

