[Python] easy to understand with explanation
Since the leading digit is not zero, the reordered number shares the same number of digits with original one.\nThe search base can be greatly reduced.\nReturn t
Since the leading digit is not zero, the reordered number shares the same number of digits with original one.\nThe search base can be greatly reduced.\nReturn true if `Counter(N) == Counter(power of 2) and NumberOfDigits(N) == NumberOfDigits(power of 2)`\n\n```python\n    def reorderedPowerOf2(self, N):\n        from collections import Counter\n\n        digits_of_n = len(str(N))\n        counter = Counter(str(N))\n        power = 1\n\n        while True:\n            digits_of_power = len(str(power))\n\n            if digits_of_power > digits_of_n:\n                break\n            \n            if digits_of_power == digits_of_n and Counter(str(power)) == counter:\n                return True\n\n            power = power*2\n\n        return False\n```
[]