def sons(A):
    """
    The sons of the configuration A for an 8Queen problem
    is obtained reducing properly the space of the solutions.
    In particular, the son is obtained changing the row index of
    one of the queen. In total we have seven possible movement 
    among the column, therefore the number of sons will be 7x8=56.
    """

    tmp_A = list(A)
    N = len(A)
    for i in range(N):
        for r in range(7):
            tmp_A = list(tmp_A)
            q = tmp_A.pop(i)
            tmp_A.insert(i, ((q[0]+1)%7, q[1]) )

            yield tmp_A

    raise StopIteration

    The sons of the configuration A for an 8Queen problem
    is obtained reducing properly the space of the solutions.
    In particular, the son is obtained changing the row index of
    one of the queen. In total we have seven possible movement 
    among the column, therefore the number of sons will be 7x8=56.
    
recipes/Python/578157_Hill_Climbing_Template_Method/recipe-578157.py