[C++] min priority queue.
\nclass Solution {\npublic:\n    int kthLargestValue(vector<vector<int>>& matrix, int k) {\n        int m = matrix.size();\n        int n = matrix[0].size();\n 
```\nclass Solution {\npublic:\n    int kthLargestValue(vector<vector<int>>& matrix, int k) {\n        int m = matrix.size();\n        int n = matrix[0].size();\n        \n        for (int i = 0; i < m; ++i) {\n            for (int j = 1; j < n; ++j) {\n                matrix[i][j] ^= matrix[i][j - 1];\n            }\n        }\n        \n        for (int j = 0; j < n; ++j) {\n            for (int i = 1; i < m; ++i) {\n                matrix[i][j] ^= matrix[i - 1][j];\n            }\n        }\n        \n        priority_queue<int, vector<int>, greater<int>> pq;\n        \n        for (int i = 0; i < m; ++i) {\n            for (int j = 0; j < n; ++j) {\n                pq.push(matrix[i][j]);\n                \n                if (pq.size() > k) {\n                    pq.pop();\n                }\n            }\n        }\n        \n        return pq.top();\n    }\n};\n```
[]