0 ms Solution,Beats 100% JAVA users,Simple Solution JAVA
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\n    public int[][] flipAndInvertImage(int[][] image) {\n        for(int i=0;i<image.length;i++){\n            int s=0,e=image.length-1;\n            while(s<=e){\n                int t=(image[i][s]+1)%2;\n                image[i][s]=(image[i][e]+1)%2;\n                image[i][e]=t;\n                s++;\n                e--;\n            }\n        }\n        return image;\n    }\n}\n```
['Two Pointers', 'Java']