Printing chessboard pattern in python for any n X m dimensions.