Lexicographically Smallest Palindrome Solution in C++
Intuition\n Describe your first thoughts on how to solve this problem. \n\n# Approach\n Describe your approach to solving the problem. \n\n# Complexity\n- Time 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n\n# Complexity\n- Time complexity:\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\nO(n)\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\nO(1)\n# Code\n```\nclass Solution {\npublic:\n    string makeSmallestPalindrome(string s) {\n        int i;\n        for(i=0 ; i<s.length()/2 ; i++)\n        {\n            if(s[i]>s[s.length()-1-i])\n            {\n                s[i] = s[s.length()-1-i];\n            }\n            else\n            {\n                s[s.length()-1-i] = s[i];\n            }\n        }\n        return s;\n    }\n};\n```\n![upvote new.jpg](https://assets.leetcode.com/users/images/69d30596-e4ec-4fc8-9dfd-f6573383ffd5_1685074084.2205186.jpeg)\n
['C++']