approach with single for loop
scan for X the skip forward by size of the move (3)\n\n\n```\n    int minimumMoves(const string& s) const {\n        int res{};\n        \n        for (size_t p
* scan for X the skip forward by size of the move (3)\n\n\n```\n    int minimumMoves(const string& s) const {\n        int res{};\n        \n        for (size_t pos = 0; pos < s.size(); pos += (s[pos] == \'X\') ? 3 : 1) {\n            res +=  (s[pos] == \'X\') ? 1 : 0;\n            \n        }\n        \n        return res;\n    }
['C']