Simple approach | C++
\nclass Solution {\npublic:\n    static bool cmp(vector<int> a, vector<int> b){\n        return a[0] < b[0];\n    }\n    vector<vector<int>> allCellsDistOrder(i
```\nclass Solution {\npublic:\n    static bool cmp(vector<int> a, vector<int> b){\n        return a[0] < b[0];\n    }\n    vector<vector<int>> allCellsDistOrder(int rows, int cols, int rCenter, int cCenter) {\n        vector<vector<int>> v;\n        for(int i=0; i<rows; i++){\n            for(int j=0; j<cols; j++){\n                int d = abs(i - rCenter) + abs(j - cCenter);\n                v.push_back({d, i, j});\n            }\n        }\n        \n        sort(v.begin(), v.end(), cmp);\n        for(vector<int> &i : v) i.erase(i.begin());\n\n        return v;\n    }\n};\n```
['C']