Did I find the right examples for you? yes no      Crawl my project      Python Jobs

All Samples(1)  |  Call(1)  |  Derive(0)  |  Import(0)
Turn row/col position (0, 0) into square (A1).
Note: A is the column, 1 is the row.

>>> squarify(0,0)
'A1'
>>> squarify(0,7)
'H1'
>>> squarify(7,0)
'A8'
>>> squarify(7,7)(more...)

        def squarify(row, col):
    """Turn row/col position (0, 0) into square (A1).
    Note: A is the column, 1 is the row.

    >>> squarify(0,0)
    'A1'
    >>> squarify(0,7)
    'H1'
    >>> squarify(7,0)
    'A8'
    >>> squarify(7,7)
    'H8'

    The Off the End of the Pier Show.
    >>> squarify(8, 1)
    Traceback (most recent call last):
    ...
    PositionException: ...
    >>> squarify(1, 8)
    Traceback (most recent call last):
    ...
    PositionException: ...

    """
    first = reverseCol(col)
    second = reverseRow(row)
    return first + str(second)
        


src/c/h/chessmind.core-0.3/chessmind/core/board.py   chessmind.core(Download)
            targetcol = temp
        while targetcol - startcol > -1:
            results.append(piece.squarify(startrow, startcol))
            startcol += 1
        return results