Binary Ballet: 🐍 Pythonic Symphony of Negabinary Precision - A 100% Tempo Triumph! 🎶✨
The time complexity of the provided solution is O(log n).\n\n# Code\n\nclass Solution:\n    def baseNeg2(self, n: int) -> str:\n        if n == 0:\n            
The time complexity of the provided solution is O(log n).\n\n# Code\n```\nclass Solution:\n    def baseNeg2(self, n: int) -> str:\n        if n == 0:\n            return "0"\n        \n        a = ""\n        while n != 0:\n            r = n % 2\n            a = str(r) + a\n            n = -(n // 2)\n        return a\n```
['Python3']