base number conversions
Tjaycool17 (0)

In the first function of the of the program, it converts a base 10 number into a base 4 number, however it drops the leading zero if there are leading zeros in the base 4 number. how do I program it to keep the leading zeros.

How would I code this to be able to covert a batch of base 4 numbers to decimal or base 10 and vice versa?

You are viewing a single comment. View All
TheDrone7 (560)

@Tjaycool17 also, be sure to keep it a string by default. It'll lose the zeroes as soon as converted to a number.