How can we reverse it

how to convert decimal to binary number system and how can we convert in octal?

Hi,

To convert decimal to binary number system, Just take the remainders by dividing it by 2 and push it in the stack. Now, remove the elements from stack to get binary number.
Similarly, divide the number by 8 and push the remainders in stack. Now remove the elements from the stack.

1 Like

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.