
    In a personalized learning system that rewards students with special star badges, determine the exact number of points needed to unlock the student's next achievement star based on their current milestone level. A star number at any achievement level follows the pattern where it equals the number of points formed by placing dots in a star shape, with each level adding a new outer layer of points to the previous star formation.
    

    
def find_star_num(n):
    """
    In a personalized learning system that rewards students with special star badges, determine the exact number of points needed to unlock the student's next achievement star based on their current milestone level. A star number at any achievement level follows the pattern where it equals the number of points formed by placing dots in a star shape, with each level adding a new outer layer of points to the previous star formation.
    

    """
def find_star_num(n):
    """
    In a personalized learning system that rewards students with special star badges, determine the exact number of points needed to unlock the student's next achievement star based on their current milestone level. A star number at any achievement level follows the pattern where it equals the number of points formed by placing dots in a star shape, with each level adding a new outer layer of points to the previous star formation.
    

    """
    return 6 * n * (n - 1) + 1