# your code goes here
import math

def get_divisors(n):
    divisors = []
    for i in range(1, int(math.isqrt(n)) + 1):
        if n % i == 0:
            divisors.extend({i, n // i})  # Use a set to avoid duplicate square roots
    return sorted(divisors, reverse=True)

# Example usage
print(*get_divisors(12))