EASY PYTHON SOLUTION
\n\npython []\nclass Solution(object):\n    def minChanges(self, n, k):\n        nbinario=bin(n)[2:] # 1101\n        kbinario=bin(k)[2:] # 100\n        largo=ma
\n\n```python []\nclass Solution(object):\n    def minChanges(self, n, k):\n        nbinario=bin(n)[2:] # 1101\n        kbinario=bin(k)[2:] # 100\n        largo=max(len(nbinario),len(kbinario) )# 4\n        tes=[]\n        nbin=nbinario.zfill(largo) # 1101\n        kbin=kbinario.zfill(largo) # 0100\n\n        count = 0\n        for i in range(largo):\n            if nbin[i]==kbin[i]:\n                tes.append(nbin[i])\n            else:\n                if nbin[i]=="1":\n                    tes.append("0")\n                    count+=1\n                else:\n                    tes.append(nbin)\n\n        res="".join(tes)   \n        if res==kbin:\n            return count \n        else:\n            return -1 \n```
['Python']