title: Converting Decimal to Two's-Complement
body: <p><strong>Instructions:</strong> Convert these decimal numbers to 5-bit 2's-complement form, if possible. If not possible, explain why this is so.</p>
  
  <p>(16) base 10</p>
  
  <p>According to the online converter:</p>
  
  <p><img src="https://i.stack.imgur.com/gVHZX.png" alt=""></p>
  
  <p>From what I understand,</p>
  
  <p>If decimal is <em>positive</em>:</p>
  
  <ul>
  <li>STEP 1: Convert magnitude to binary.</li>
  <li>STEP 2: Pad 0's to desired bitsize.</li>
  </ul>
  
  <p>If decimal is <em>negative</em>:</p>
  
  <ul>
  <li>STEP 1: Convert magnitude to binary.</li>
  <li>STEP 2: Pad 0's to desired bitsize.</li>
  <li>STEP 3: Invert bits to achieve 1's-complement.</li>
  <li>STEP 4: Add 1 to achieve 2's-complement.</li>
  </ul>
  
  <p>Since 16 is positive, I simply converted it to binary by repeated division yielding (10000) base 2.</p>
  
  <p>I no longer padded 0's since it is already 5-bits (containing 5 digits).</p>
  
  <p>Can somebody explain to me why the online converter is returning an error (which also I strongly believe is the correct answer)?</p>