🚀 Fastest Bit Manipulation: Transform Numbers in Just 3 Lines! 🔥✨
Intuition\n Describe your first thoughts on how to solve this problem. \nThis approach identifies which bits differ between the numbers and checks if combining 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\nThis approach identifies which bits differ between the numbers and checks if combining these differences with the target number recreates the original number.\n\n# Approach\nThis solution finds the minimum changes needed to transform one number into another using three steps:\n\n1. **Identify Differences:** It first finds which bits (binary digits) differ between the two numbers.\n2. **Combine Bits:** Then, it combines these differences with the target number to see if the original number can be recreated.\n3. **Count Changes:** Finally, if the numbers match, it counts the number of changes needed; if they don\'t match, it returns -1.\n\n# Complexity\n- Time complexity: O(1)\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity: O(1)\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution {\npublic:\n    int minChanges(int n, int k) {\n        int a = n ^ k;\n        int b = k | a;\n        return (b == n) ? __builtin_popcount(a) : - 1;\n    }\n};\n```
['C++']