def get_divisors_count(num):
count = 0
for i in range(1, num + 1):
if num % i == 0:
count += 1
return count
def get_numbers_with_six_or_more_divisors
:
result = []
for i in range(1, n + 1):
divisors = [j for j in range(1, i + 1) if i % j == 0]
if len(divisors) >= 6:
result.append((i, divisors))
return result
n = 50 # можно выбрать любое значение n
numbers_list = get_numbers_with_six_or_more_divisors
for num, divisors in numbers_list:
print(f"Число: {num}, делители: {divisors}"