Moved board's string representation logic to Board class.