Simple for loop || Beginner Approach || C++best Solution ;
\t\tif(p.length() == 1) return "";      // only case we not able to make solution ;\n        for(int i=0; i<p.length()/2; i++){      // if we use loop till leng
\t\tif(p.length() == 1) return "";      // only case we not able to make solution ;\n        for(int i=0; i<p.length()/2; i++){      // if we use loop till lenght it will give wrong output on "aba" ;\n            if(p[i] != \'a\') {\n\t\t\t\tp[i] = \'a\';\n                return p;\n\t\t\t}\n        }\n        p[p.length()-1] = \'b\';\n        return p;\n\t\t\n\t\t\n\t\t\n**share your experience in comment box**
['C', 'Java']