DEV Community

Azat Toroyan
Azat Toroyan

Posted on

Binary Arithmetic: Addition, Subtraction, Multiplication & Division

Binary numbers are the foundation of all digital systems, and understanding binary arithmetic is critical for anybody interested in computer science or electronics.

Binary Addition

Binary addition works like decimal addition but only involves 0s and 1s. You add from right to left, carrying over a 1 when the sum reaches 2.

Example: 1011 + 1101 = 11000

Binary Subtraction

When subtracting in binary, you may need to borrow, just like in decimal subtraction. If the top digit is smaller, borrow from the next column.

Example: 1101 - 1011 = 0010

Binary Multiplication

Binary multiplication follows a similar process as decimal multiplication, with each row shifted left before adding the results.

Example: 101 ร— 11 = 1111

Binary Division

Binary division is a process of repeated subtraction.

Example: 10110 รท 11 = 111 Remainder 1

For better visualization and understanding watch my YouTube video with the link down below.

YouTube Video

-Azat Toroyan

Top comments (0)