hello, this is on a practice test:
It prints out x in binary format, but when I do it by hand I get the binary format backwards. when recur(x/2) is called and x is 1, it prints 1 and then i go back up the tree and print out all the other remainders of 2. what am i doing wrong?Code:void recur (int x) { if (x != 0) recur(x/2); printf("%d", x%2); }