Very Simple Code Bit Manu. || C++
\nclass Solution\n{\npublic:\n    int mod = 1e9 + 7;\n\n    int concatenatedBinary(int n)\n    {\n        long long ans = 0;\n        int i = 1;\n\n        whil
```\nclass Solution\n{\npublic:\n    int mod = 1e9 + 7;\n\n    int concatenatedBinary(int n)\n    {\n        long long ans = 0;\n        int i = 1;\n\n        while (i <= n)\n        {\n            int leftShift = log2(i) + 1;\n            ans <<= leftShift;\n            ans = (ans | i++) % mod;\n        }\n\n        return (ans % mod);\n    }\n};\n```
['C']