Static Zero

Writing What We Want

Static Zero header image 4

All About Binary

April 24th, 2008 · No Comments · Programming, Random

This post contains information on how to convert decimal numbers to binary, 1’s complement, 2’s complement, and binary coded decimal. I’ve tried breaking it up to keep it somewhat organized, so hopefully you can follow.

[Read more →]

Tags:·····

Convert Decimal to 2’s Complement Binary in C

April 24th, 2008 · 2 Comments · Programming

I was writing a program recently, and I needed a function that would convert a given decimal number to 2’s Complement (signed) binary. It’s simple enough to convert an unsigned integer to binary, but the sign (especially 2’s comp) makes it tricky. Since I couldn’t find a function to do this for me, I […]

[Read more →]

Tags:·