結果 : how to check rows and columns in python