title: Why do I keep getting back 1011 rather than 1101?
body: <p>So, the question is.</p>
  
  <p>What does the recursive code below print when called with number = 13 and base = 2?</p>
  
  <pre><code>public static void convert(int number, int base) {
  
  int remainder = number % base;
  int quotient = number / base;
  
  if (quotient &gt; 0) convert(quotient, base);
  System.out.print(remainder);
  </code></pre>
  
  <p>I've been running through this on paper for about an hour and no matter what i keep coming up with 1011 rather than 1101.</p>
  
  <p>Am I just doing the math wrong or what?</p>