C++ beat 99 clean code with comment
\nclass Solution {\npublic:\n    vector<vector<char>> rotateTheBox(vector<vector<char>>& box) {\n        for(int i = 0 ; i < box.size() ; i++) {\n            in
```\nclass Solution {\npublic:\n    vector<vector<char>> rotateTheBox(vector<vector<char>>& box) {\n        for(int i = 0 ; i < box.size() ; i++) {\n            int space = INT_MIN;\n            for(int j = box[0].size()-1 ; j >=0 ; j--){\n                // meet obstacle, remove space\n                if(box[i][j] == \'*\'){\n                    space = INT_MIN;\n                }\n                else if(box[i][j] == \'#\'){\n                    //meet stone and has space for it\n                    //drop the stone to where the space is, the this position become another space\n                    if(space != INT_MIN){\n                        box[i][space--] = \'#\';\n                        box[i][j] = \'.\';\n                    }\n                } else {\n                    // update most right space, only for first space actually\n                    space = max(space,j);\n                }\n            }\n        }\n        // rotate the box\n        vector<vector<char>> res(box[0].size(),vector<char>(box.size()));\n        for(int i = 0 ; i < box[0].size() ; i++)\n            for(int j = 0 ; j < box.size() ; j++)\n                res[i][j] = box[box.size()-1-j][i];\n        return res;\n    }\n};\n```
[]