C Solution | O(n/2)
Second Solution\n\nint** flipAndInvertImage(int** A, int ASize, int* AColSize, int* returnSize, int** returnColumnSizes){\n    *returnSize= ASize;\n    *returnC
Second Solution\n```\nint** flipAndInvertImage(int** A, int ASize, int* AColSize, int* returnSize, int** returnColumnSizes){\n    *returnSize= ASize;\n    *returnColumnSizes = AColSize;\n    float col = *AColSize;\n    col/=2;\n    for(int i=0, tmp;i<ASize;i++)\n        for(int j=0;j<col;j++){\n            tmp = A[i][(*AColSize-1)-j];\n            A[i][(*AColSize-1)-j] = !A[i][j];\n            A[i][j] = !tmp;\n        }\n    return A;\n}\n\n\n\n```\n\nFirst Solution\n\n```\nint** flipAndInvertImage(int** A, int ASize, int* AColSize, int* returnSize, int** returnColumnSizes){\n    int **flipped = (int**)malloc(sizeof(int*)*(*returnSize= ASize));\n    for(int i=0;i<ASize;i++){\n        flipped[i] = malloc(sizeof(int)*(*(*returnColumnSizes = AColSize)));\n        for(int j=0;j<*AColSize;j++)\n            flipped[i][(*AColSize-1)-j] = !A[i][j];}\n    return flipped;\n}
['C']