# data[].attributes.body
A variable, in the context of programming, is a symbolic name given to an unknown quantity that permits the name to be used independent of the information it represents. Variables are associated with data storage locations, and values of a variable are normally changed during the course of program execution.

变量，在编程的背景下，是给未知量的一个符号名称，允许该名称的使用与它代表的信息无关。变量与数据存储位置相关，变量的值通常在程序执行过程中改变。

# data[].attributes.body
+ Addition 加法运算符
- Subtraction 减法运算符
* Multiplication 乘法运算符
/ Division 部门操作员
% Modulus 模数运算符
// Integer Division 整数除法运算符
** Power 电力运营商
= Assignment 赋值运算符

# data[].attributes.body
> Greater than 大于运算符
< Less than 小于运算符
>= Greater than equal to 大于等于运算符
<= Less than equal to 小于等于运算符
== Comparison 比较运算符
!= Not equal to 不等于运算符

# data[].attributes.body
and  逻辑和运算符
or 逻辑或运算符
not 逻辑非运算符

# data[].attributes.body
example myVar = 10

# data[].attributes.body
myVariable = 10.345

# data[].attributes.body
myName = "John Doe"

# data[].attributes.body
myDecision = True

# data[].attributes.body
A binary number system is one of the four types of number system. In computer applications, where binary numbers are represented by only two symbols or digits, i.e. 0 (zero) and 1(one). The binary numbers here are expressed in the base-2 numeral system.

二进制数系统是四种类型的数系统之一。在计算机应用中，其中二进制数仅由两个符号或数字表示，即0（零）和1（一）。这里的二进制数是用基数2数字系统表示的。

# data[].attributes.attachment_link.readable_text
A binary number system is one of the four types of number system. In computer applications, where binary numbers are represented by only two symbols or digits, i.e. 0 (zero) and 1(one). The binary numbers here are expressed in the base-2 numeral system. For example, (101) is a binary number. Each digit in this system is said to be a bit. Learn about the number system here.

Number System is a way to represent the numbers in the computer architecture. There are four different types of the number system, such as:

In this article, let us discuss what is a binary number system, conversion from one system to other systems, table, positions, binary operations such as addition, subtraction, multiplication, and division, uses and solved examples in detail.

What is a Binary Number System?

Binary Number System: According to digital electronics and mathematics, a binary number is defined as a number that is expressed in the binary system or base 2 numeral system. It describes numeric values by two separate symbols; 1 (one) and 0 (zero). The base-2 system is the positional notation with 2 as a radix.

The binary system is applied internally by almost all latest computers and computer-based devices because of its direct implementation in electronic circuits using logic gates. Every digit is referred to as a bit.

What is Bit in Binary Number?

A single binary digit is called a " Bit". A binary number consists of several bits. Examples are:

10101 is a five-bit binary number

101 is a three-bit binary number

100001 is a six-bit binary number

Facts to Remember:

Binary numbers are made up of only 0's and 1's.

A binary number is represented with a base-2

A bit is a single binary digit.

Binary Numbers Table

Some of the binary notations of lists of decimal numbers from 1 to 30, are mentioned in the below list.

How to Calculate Binary Numbers

For example, the number to be operated is 1235.

This indicates,

1235 = 1 × 1000 + 2 × 100 + 3 × 10 + 5 × 1

Given,

The above table can be described as,

Hence,

1235 = 1 × 1000 + 2 × 100 + 3 × 10 + 5 × 1

The decimal number system operates in base 10, wherein the digits 0-9 represent numbers. In binary system operates in base 2 and the digits 0-1 represent numbers, and the base is known as radix. Put differently, and the above table can also be shown in the following manner.

We place the digits in columns 10 ⁰, 10 ¹ and so on in base 10. When there is a need to put a value higher than 9 in the form of 10(n+1) for instance, to add 10 to column 10 ⁰, you need to add 1 to the column 10 ¹.

We place the digits in columns 2 ⁰, 2 ¹ and so on in base 2. To place a value that is higher than 1 in 2 n, you need to add 2(n+1). For instance, to add 3 to column 2 ⁰, you need to add 1 to column 2 ¹.

Position in Binary Number System

In the Binary system, we have ones, twos, fours etc...

For example 1011.110

It is shown like this:

1 × 8 + 0 × 4 + 1 × 2 + 1 + 1 × ½ + 1 × ¼ + 0 × 1⁄8

= 11.75 in Decimal

To show the values greater than or less than one, the numbers can be placed to the left or right of the point.

For 10.1, 10 is a whole number on the left side of the decimal, and as we move more left, the number place gets bigger (Twice).

The first digit on the right is always Halves ½ and as we move more right, the number gets smaller (half as big).

In the example given above:

"10" shows '2' in decimal.

".1" shows 'half'.

So, "10.1" in binary is 2.5 in decimal.

Binary Arithmetic Operations

Like we perform the arithmetic operations in numerals, in the same way, we can perform addition, subtraction, multiplication and division operations on Binary numbers. Let us learn them one by one.

Binary Addition

Adding two binary numbers will give us a binary number itself. It is the simplest method. Addition of two single-digit binary number is given in the table below.

Let us take an example of two binary numbers and add them.

For example: Add 1101 ₂ and 1001 ₂.
Solution:

Binary Subtraction

Subtracting two binary numbers will give us a binary number itself. It is also a straightforward method. Subtraction of two single-digit binary number is given in the table below.

Let us take an example of two binary numbers and subtract them.

Binary Multiplication

The multiplication process is the same for the binary numbers as it is for numerals. Let us understand it with example.

Solution:

Binary Division

The binary division is similar to the decimal number division method. We will learn with an example here.

Solution:

Uses of Binary Number System

Binary numbers are commonly used in computer applications. All the coding and languages in computers such as C, C++, Java, etc. use binary digits 0 and 1 to write a program or encode any digital data. The computer understands only the coded language. Therefore these 2-digit number system is used to represent a set of data or information in discrete bits of information.

Problems and Solutions

Let us practice some of the problems for better understanding:

Question 1: What is binary number 1.1 in decimal?
Solution:
Step 1: 1 on the left-hand side is on the one's position, so it's 1.

Step 2: The one on the right-hand side is in halves, so it's

Step 3: so, 1.1 = 1.5 in decimal.
Solution:
So, 10.11 is 2.75 in Decimal.

Keep visiting BYJU'S to explore and learn more such Math-related topics in a fun and engaging way.

Frequently Asked Questions - FAQs

What is a binary number system?

A number system where a number is represented by using only two digits (0 and 1) with a base 2 is called a binary number system. For example, 10012 is a binary number.

What is a bit?

A bit is a single digit in the binary number. For example, 101 is three-bit binary numbers, where 1, 0 and 1 are the bits.

How to convert a decimal number into a binary number? Give an example.

To convert a decimal number into its equivalent binary number, we divide the decimal number by 2 each time, till we get 0 as a dividend. Let us take an example to convert 1310 into a binary number.
13 ÷ 2: 6 and remainder 1
6 ÷ 2: 3 and remainder 0
3 ÷ 2: 1 and remainder 1
1 ÷ 2: 0 and remainder 1
Now we take the bits from the last remainder to first remainder, i.e.(MSB to LSB). Hence,
13 ₁₀ = 1101 ²

What is the use of binary numbers?

Binary numbers are commonly used in computer architecture. Since the computer understands only the language of two digits 0's and 1's, therefore the programming is done using a binary number system.

What is the value of 163 in binary?

The value of 163 in binary is 10100011.

How is 200 represented in binary?

200 is the decimal number. The binary form of 200 is 110010002.

# data[].attributes.attachment_link.title
Binary Number System (Definition, Decimal to Binary)

# data[].attributes.attachment_link.description
A binary number system is one of the four types of number system. In computer applications, where binary numbers are represented by only two symbols or digits, i.e. 0 (zero) and 1(one). The binary numbers here are expressed in the base-2 numeral system. For example, (101) is a binary number.

# data[].attributes.body
A number system that uses a notation in which each number is expressed in base 10 by using one of the first nine integers or 0 in each place and letting each place value be a power of 10.

一种数字系统，使用一种符号，其中每个数字以10为基数表示，在每个位置上使用前九个整数之一或0，并让每个位置的值是10的幂。