simple 100% , one loop
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)$$ -->\n\n- Space complexity:\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nfunc longestPalindrome(s string) int {\n\tcharMap := make(map[byte]int)\n\tvar length int\n\n\tfor _, c := range []byte(s) {\n\t\tcharMap[c]++\n\t\tnum := charMap[c]\n\t\tif num == 2 {\n\t\t\tlength = length + 2\n\t\t\tdelete(charMap, c)\n\t\t}\n\t}\n\n\n\tif len(charMap) != 0 {\n\t\tlength++\n\t}\n\n\treturn length\n}\n\n```
['Go']