Write an Algorithm and draw a flowchart that will convert a given decimal number (N10) to its equivalent Binary number (N2).
1. If N10 is 0, set N2 equal 0 and go to step 8
2. Set N2 as an empty string
3. If N10 equal 0, go to step
4. Set D equal the remainder of dividing N10 by 2
5. Add D as the leftmost digit to N2
6. Set N10 equal quotient of dividing N10 by 2
7. Go to step 3
8. Stop
Comments
Leave a comment