[C++] 9 lines, 15ms
\nint maxChunksToSorted(vector<int>& arr) {\n        int sum1 = 0, sum2 = 0, ans = 0;\n        vector<int> t = arr;\n        sort(t.begin(), t.end());\n        
```\nint maxChunksToSorted(vector<int>& arr) {\n        int sum1 = 0, sum2 = 0, ans = 0;\n        vector<int> t = arr;\n        sort(t.begin(), t.end());\n        for(int i = 0; i < arr.size(); i++) {\n            sum1 += t[i];\n            sum2 += arr[i];\n            if(sum1 == sum2) ans++;\n        }\n\treturn ans;\n    }\n```
[]