EASY JAVA SOLUTION
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```\nclass Solution {\n    public int[] evenOddBit(int n) {\n    int[] arr = { 0, 0 };\n\t\tStringBuilder ss = new StringBuilder(Integer.toString(n, 2));\n\t\tss.reverse();\n\t\tfor (int i = 0; i <= ss.length() - 1; i++) {\n\t\t\tif (i % 2 == 0 && ss.charAt(i) == \'1\') {\n\t\t\t\tarr[0] = arr[0] + 1;\n\t\t\t} else if (i % 2 == 1 && ss.charAt(i) == \'1\') {\n\t\t\t\tarr[1] = arr[1] + 1;\n\t\t\t}\n\t\t}          \n        return arr;\n    }\n}\n```
['Java']