Python | XOR | Simplest Solution | Beats 97%
\nclass Solution:\n    def flipAndInvertImage(self, image: List[List[int]]) -> List[List[int]]:\n        for i in range(len(image)):\n            start = 0\n   
```\nclass Solution:\n    def flipAndInvertImage(self, image: List[List[int]]) -> List[List[int]]:\n        for i in range(len(image)):\n            start = 0\n            end = len(image[i]) - 1\n            while start <= end:\n                image[i][start], image[i][end] = image[i][end]^1, image[i][start]^1\n                start += 1\n                end -= 1\n        return image\n```\n\n***If you liked the above solution then please upvote!***
['Python']