0

I haven't been able to find a conclusive answer to my query. Is there any way we can represent a number in its binary representation but as a string? Then convert that string to the 32-bit unsigned integer.

As an example suppose we have the following binary number:

00000000000000000000000000001011

We want to represent it as a string:

"00000000000000000000000000001011"

However, I want to convert this thing back to the binary number and, eventually, it's integer form which would be 11. Does anyone have any idea how to do this in python?

2
  • Answers here and here. Commented Oct 9, 2022 at 17:22
  • There is no "binary type" in Python. Commented Oct 9, 2022 at 17:22

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.