You are on page 1of 50

Chapter-1

DIGITAL FUNDAMENTALS

TECHNICAL AND VOCATIONAL TRAINING INSTITUTE


Department of Electrical electronics technology

Digital Logic Design


EETe 3032

By Zemenu T. /2023
1
Outlines

1. Fundamentals of Digital Electronics


2. Number Systems
3. Binary codes
4. Signed and unsigned numbers

2
Digital and Analog Quantities
In science, technology, business, and, in fact, most other fields of endeavour, we are constantly dealing
with quantities. Quantities are measured, monitored, recorded, manipulated arithmetically, observed, or in
some other way utilized in most physical systems. It is important when dealing with various quantities that
we can be able to represent their values efficiently and accurately. There are basically two ways of
representing the numerical value of quantities: analog and digital

In analog representation a quantity is represented by a voltage, current, or meter movement that is


proportional to the value of that quantity. Analog quantities such as shown in figure 1-1 have an important
characteristic: they can vary over a continuous range of values. (can be analog voltage versus time) where
as in digital representation the quantities are represented not by proportional quantities but by symbols
called digits.
The main difference between analog and digital electronics can be stated simply. Analog voltages or
currents are continuously variable between defined values and digital voltages, or currents can vary only
by distinct, or discrete, steps.
3
Here below, the differences between digital and analog electronics is highlighted:
Analog Digital
• Continuously variable • Discrete steps
• Has continuous value • Has only two values (max & min)
• There are so many intermediate values b/n max & • There are no any intermediate values b/n max & min
min values values

a) analog b) digital
Figure 1.1. Analog and digital signals.
Advantages and Limitations of Digital Systems:
Advantages:
▪ Digital systems are easier to design
▪ Information storage is easy
▪ Accuracy and precision are greater
▪ Digital systems are more versatile
▪ Digital circuits are less affected by noise 4
Disadvantages:

There is really only one major drawback when using digital techniques: “The real world is
mainly analog” and we need an interface/translator between the real world and digital
systems. Circuits which can perform this task are called Analog to Digital Convertors
(ADC) and Digital to Analog Convertors (DAC).

The following three steps should be followed when dealing with analog inputs and
outputs to take advantage of digital techniques:

• Convert the real-world analog inputs to digital form. (ADC)


• Process (operate on) the digital information.
• Convert the digital outputs back to real-world analog form. (DAC).

5
Logic level and pulse wave forms:

▪ Logic level: A voltage level that represents a defined digital state in an electronic circuit.
▪ Logic HIGH (or logic 1) The higher of two voltages in a digital system with two logic levels.
▪ Logic LOW (or logic 0) The lower of two voltages in a digital system with two logic levels.
▪ Positive logic: A system in which logic LOW represents binary digit 0 and logic HIGH represents binary
digit 1.
▪ Negative logic A system in which logic LOW represents binary digit 1 and logic HIGH represents binary
digit 0.

Digital Circuit: An electronic circuit that handles only a digital signal (i.e., designed to operate with a fixed
number of discrete voltage values).

Example: Digital calculator, Digital computer

The digital operation is a two - state operation (i.e. ON or OFF, 1 or 0) and therefore a digital circuit uses
only two digits 1 and 0 in the binary number system. To understand the concepts in digital circuits, first we
discuss about the number system in the following sections. 6
Number Systems

This part introduces some basic number system concepts and those useful in electrical,
electronics, and computer engineering.
A number system is nothing more than a code that uses symbols to refer to a number of items.
The binary number system and digital codes are fundamental to computers and to digital
electronics in general.
Number system is commonly used to count any activity or articles. In practical life, we are using
decimal number system. In decimal number system, 10 digits (0,1,2,3,4,5,6,7,8,9) are used. But
in digital electronics, we use ‘1’ and ‘0’.
Computers, microprocessor, and digital electronic devices do not process decimal numbers.
Instead, they work with binary number, which use only the two digits ‘0’ and’1’.
People do not like working with binary numbers, owing to their very lengthy combinations of
digits, while representing larger decimal values.
As a result, octal and hexadecimal numbers are widely used to compress long strings of binary
numbers. Some number systems are discussed below.
7
Decimal Number System
In the decimal, base-10, each integer number column has values of units, tens, hundreds, thousands, etc
as we move along the number from right to left. Mathematically these values are written as 100, 101, 102,
103 etc. Then each position to the left of the decimal point indicates an increased positive power of 10.
Likewise, for fractional numbers the weight of the number becomes more negative as we move from left to
right, 10-1, 10-2, 10-3 etc.
So we can see that the “decimal numbering system” has a base of 10 with the position of each digit in the
decimal system indicating the magnitude or weight of that digit as q is equal to “10” (0 through 9). For
example, 20 (twenty) is the same as saying 2 x 101 and therefore 400 (four hundred) is the same as saying
4 x 102.
The value of any decimal number will be equal to the sum of its digits multiplied by their respective
weights. For example: N = 616310 (Six Thousand One Hundred and Sixty Three) in a decimal format is
equal to:
6000 + 100 + 60 + 3 = 6163
or it can be written reflecting the weight of each digit as:
( 6×1000 ) + ( 1×100 ) + ( 6×10 ) + ( 3×1 ) = 6163
or it can be written in polynomial form as:
( 6×103 ) + ( 1×102 ) + ( 6×101 ) + ( 3×100 ) = 6163
Where in this decimal numbering system example, the left most digit is the most significant digit, or MSD,
and the right most digit is the least significant digit or LSD. In other words, the digit 6 is the MSD since its
left most position carries the most weight, and the number 3 is the LSD as its right most position carries the
8
least weight.
Binary Number System
The Binary Numbering System is the most fundamental numbering system in all digital
and computer based systems and binary numbers follow the same set of rules as the
decimal numbering system. But unlike the decimal system which uses powers of ten, the
binary numbering system works on powers of two giving a binary to decimal conversion
from base-2 to base-10.
Digital logic and computer systems use just two values or states to represent a condition,
a logic level “1” or a logic level “0”, and each “0” and “1” is considered to be a single digit
in a Base-of-2 (bi) or “binary numbering system”.
In the binary numbering system, a binary number such as 101100101 is expressed with
a string of “1’s” and “0’s” with each digit along the string from right to left having a value
twice that of the previous digit. But as it is a binary digit it can only have a value of either
“1” or “0” therefore, q is equal to “2” (0 or 1) with its position indicating its weight within
the string.
As the decimal number is a weighted number, converting from decimal to binary (base
10 to base 2) will also produce a weighted binary number with the right-hand most bit
being the Least Significant Bit or LSB, and the left-hand most bit being the Most
9
Significant Bit or MSB, and we can represent this as:
Representation of a Binary Number
MSB Binary Digit LSB
28 27 26 25 24 23 22 21 20
256 128 64 32 16 8 4 2 1
We saw above that in the decimal number system, the weight of each digit to the left increases by a
factor of 10. In the binary number system, the weight of each digit increases by a factor of 2 as
shown. Then the first digit has a weight of 1 ( 20 ), the second digit has a weight of 2 ( 21 ), the third a
weight of 4 ( 22 ), the fourth a weight of 8 ( 23 ) and so on. So for example, converting a Binary to
Decimal number would be:
Decimal Digit Value 256 128 64 32 16 8 4 2 1
Binary Digit Value 1 0 1 1 0 0 1 0 1
By adding together ALL the decimal number values from right to left at the positions that are
represented by a “1” gives us: (256) + (64) + (32) + (4) + (1) = 35710 or three hundred and fifty seven
as a decimal number.
Then, we can convert binary to decimal by finding the decimal equivalent of the binary array of digits
1011001012 and expanding the binary digits into a series with a base of 2 giving an equivalent of
10
35710 in decimal.
Basic Binary Arithmetic
Binary addition, subtraction, multiplication and division operations work essentially the same as they do for
decimals. For addition, you add equally weighted bits, much like decimal addition (where you add equally
weighted digits) and carry as required to the left.
Result=Carry x Base + Remainder

11
Result=Carry x Base + Remainder

12
Octal Number System
The Octal Number System is another type of computer and digital base number system. The
Octal Numbering System is very similar in principle to the hexadecimal numbering system
except that in Octal, a binary number is divided up into groups of only 3 bits, with each group or
set of bits having a distinct value of between 000 (0) and 111 ( 4+2+1 = 7 ).
Octal numbers therefore have a range of just “8” digits, (0, 1, 2, 3, 4, 5, 6, 7) making them a
Base-8 numbering system and therefore, q is equal to “8”.
Then the main characteristics of an Octal Numbering System is that there are only 8 distinct
counting digits from 0 to 7 with each digit having a weight or value of just 8 starting from the least
significant bit (LSB). In the earlier days of computing, octal numbers and the octal numbering
system was very popular for counting inputs and outputs because as it works in counts of eight,
inputs and outputs were in counts of eight, a byte at a time.
As the base of an Octal Numbers system is 8 (base-8), which also represents the number of
individual numbers used in the system, the subscript 8 is used to identify a number expressed in
octal. For example, an octal number is expressed as: 2378
Just like the hexadecimal system, the “octal number system” provides a convenient way of
converting large binary numbers into more compact and smaller groups. However, these days
the octal numbering system is used less frequently than the more popular hexadecimal
13
numbering system and has almost disappeared as a digital base number system.
Representation of an Octal Number
MSB Octal Number LSB
88 87 86 85 84 83 82 81 80
16M 2M 262k 32k 4k 512 64 8 1

As the octal number system uses only eight digits (0 through 7) there are no numbers or
letters used above 8, but the conversion from decimal to octal and binary to octal follows
the same pattern as for hexadecimal.
To count above 7 in octal we need to add another column and start over again in a
similar way to hexadecimal.
0, 1, 2, 3, 4, 5, 6, 7, 10, 11, 12, 13, 14, 15, 16, 17, 20, 21….etc
Again do not get confused, 10 or 20 is NOT ten or twenty it is 1 + 0 and 2 + 0 in octal
exactly the same as for hexadecimal. The relationship between binary and octal
14
numbers is given below.
Octal Numbers
Decimal 3-bit Binary Octal Arithmetic: octal arithmetic, like binary
Octal Number
Number Number
0 000 0 arithmetic, follows the same rules and patterns of
1 001 1 decimal arithmetic. As an exercise, verify the
2 010 2 following:
3 011 3 328 + 568 = 1108 328 x 568 = 22548
4 100 4
5 101 5
6 110 6
7 111 7
8 001 000 10 (1+0)
9 001 001 11 (1+1)
Continuing upwards in groups of three
15
Hexa-decimal Number

The one main disadvantage of binary numbers is that the binary string equivalent of a
large decimal base-10 number can be quite long. When working with large digital
systems, such as computers, it is common to find binary numbers consisting of 8, 16 and
even 32 digits which makes it difficult to both read or write without producing errors
especially when working with lots of 16 or 32-bit binary numbers.
One common way of overcoming this problem is to arrange the binary numbers into
groups or sets of four bits (4-bits). These groups of 4-bits uses another type of
numbering system also commonly used in computer and digital systems called
Hexadecimal Numbers.

16
Hexa-decimal Number

The most commonly used number system in computer systems is the hexadecimal, or
more simply hex, system. It has a radix of 16, and uses the numbers zero through nine,
as well as A through F as its digits:

17
Hexa-decimal Number Decimal 4-bit Binary Hexadecimal
Number Number Number
0 0000 0
1 0001 1
2 0010 2
3 0011 3
4 0100 4
5 0101 5
6 0110 6
7 0111 7
8 1000 8
9 1001 9
10 1010 A
11 1011 B
12 1100 C
13 1101 D
14 1110 E
15 1111 F
16 0001 0000 10 (1+0)
17 0001 0001 11 (1+1)
18
Continuing upwards in groups of four
Hexa-decimal Arithmetic
Hex arithmetic, yet again, follows the same rules and patterns of decimal arithmetic.
As an exercise, verify the following:
3216 x 5616 = 8816
3216 x 5616 = 10CC16

19
Conversion of number systems
Conversion of binary number from one number format to another number format can be
performed by adapting some rules and regulations. Some of the important conversion
processes are explained below. For the conversion of integer and fractional number,
separate conversion methods are used.

Binary to Decimal Conversion

When you consider a binary number in exponential form, you can easily perform a
decimal conversion: 01102 = 0 x 23 + 1 x 22 + 1 x 21 + 0 x 20.
Simply add up the factors: 0 x 23 + 1 x 22 + 1 x 21 + 0 x 20 = 0 + 4 + 2 + 0 = 6
To convert from decimal to binary, you can repeatedly divide the decimal by two until
the result of the division is zero. Starting from the rightmost bit, write 1 if the division has
20
a remainder, zero if it does not. For example, to convert the decimal 74 into binary:
Binary to Decimal Conversion

21
Decimal Fractions-to-Binary is done by repeated multiplication of 2. Here bellow, figure
1.2, you can observe the illustration:

Figure 1.2. Illustration of decimal fractions to binary conversion.


22
As it is shown above, you multiply the fraction by 2 until the fraction part gets zero.
Indeed, here, the carries are the one to be collected in the reverse way of repeated
division method. The following example, shown in figure 1.3, illustrates both.

Figure 1.3. Illustration of decimal to binary conversion including fractions. 23


Binary to Octal Conversion

Each octal digit is represent able by exactly three bits. This becomes obvious when you
consider that the highest octal digit is seven, which can be represented in binary by 1112.
To convert a binary number to octal, group the bits in groups of three starting from the
rightmost bit and convert each triplet to its octal equivalent.
1000100111012 = (100 010 011 101)2 = (4 2 3 5)8 = 42358
To convert an octal number to binary, simply write the equivalent bits for each octal
number.
7528 = (111 101 010)2 = 1111010102
To perform binary-to-octal conversion, we partition the binary number into groups of three
digits each starting from the binary point and proceeding to the left for the integer part and to
the right of the binary point for the fractional part.
24
Class activity

Convert the binary number (10110001101011.1111)2 to its octal equivalent.

25
Converting Octal Number to equivalent Binary

Conversion from octal-to-binary is accomplished in the reverse procedure of the above,


i.e. each octal digit is converted to its binary equivalent.
Example
Convert the octal number (673.124)8 to its binary equivalent

Solution: Here, we replace each octal digit by its binary equivalent, i.e.,
(673.124)8 = 110 111 011 . 001 010 100
6 7 3 . 1 2 4
Therefore, (673.124)8 = (110111011.001010100)2

26
Decimal to Octal Conversion
The repeated-division (or Double-dabble) method described for binary will also work for
octal, simply by changing the divisor to eight. To convert 67 (base 10 into octal):

27
Hexa-decimal to Binary Conversion

Converting Binary Number to equivalent Hexadecimal

To perform binary-to-hexadecimal conversion, we partition the binary


number into groups of four digits each starting from the binary point and
proceeding to the left for the integer part and to the right of the binary point
for the fractional part
Example 1.3

Convert the binary number (10110001101011.111101)2 to its hexadecimal equivalent

28
Converting Binary Number to equivalent Hexadecimal (Contd.)

Solution: For this example, we insert two leading zeros to the left of the integer part
and two zeros to the right of the decimal part, we partition the given binary number in
groups of four digits, and we assign the equivalent hexadecimal digit to each binary
group, that is,
0010 1100 0110 1011 . 1111 0100
2 C 6 B . F 4
Therefore,
(10110001101011.111101)2 = (2C6B.F4)16

29
Converting Hexadecimal Number to equivalent Binary

Conversion from hexadecimal-to-binary is accomplished in the reverse procedure of the


above, i.e. each hexadecimal digit is converted to its binary equivalent - each hex digit is
representable by exactly four bits. This becomes obvious when you consider that the
highest hex digit represents fifteen, which can be represented in binary by 11112.

Example

Convert the hexadecimal number (306.D)16 to its binary equivalent

Solution: 3 0 6 . D
0011 0000 0110 . 1101
Therefore,
(306. D)16 = (1100000110.1101)2
30
Converting Hexadecimal Number to equivalent Octal and vice versa

There is no direct method of conversion between octal and hexadecimal. Conversion


can be carry out by either of the following methods:
1.By converting hexadecimal (octal) to binary then binary result to octal (hexadecimal).
2.By converting hexadecimal (octal) to decimal then decimal result to octal
(hexadecimal).

31
Binary Codes
All digital circuits operate with only two states namely, High and Low or ON and OFF or
1 and 0. In binary number system, the number of bits required goes on increasing as
the numbers become larger and larger. So, some special binary codes are required to
represent alphabets and special characters. Based on these points, different types of
binary code have been developed.
Binary Coded Decimal

The Binary Coded Decimal (BCD) uses 4 bits to represent the decimal numbers through
and these are shown in the Table 1.1 along with other coding types.
As it can be observed from the table, only ten of the sixteen (24) possible combinations
are used in BCD; the remaining six combinations 1010, 1011, 1100, 1101, 1110, and
1111are invalid in BCD.
Since in BCD we require four bits to represent a single decimal character, a decimal
number between 10 and 99 must be represented with 8 bits, a decimal number between
100 and 999 will require 12 bits in BCD, and so on. In general, a decimal number with n
digits in BCD must be represented by 4n bits. 32
Example 1.5
Express (10)10, (279)10 , and (53904)10 in BCD

Solution: (10)10 = (0001 0000)BCD


(279)10 = (0010 0111 1001)BCD
(53904)10 = (0101 0011 1001 0000 0100)BCD

Excess – three code


The Excess-3 code also uses 4 bits to represent the decimal numbers 0 through 9 and
these are shown in the Table 1.1. The Excess-3 Code derives its name from the fact that
each decimal representation in Excess-3 code is larger than the BCD code by three.
The advantage of the Excess-3 code over the BCD code is that the Excess-3 code is a
self-complementing code as illustrated in the table.
33
Gray-code
In Gray Code only a single bit changes between successive numbers. This is very desirable
in certain applications such as optical or mechanical shaft position encoders, and digital-to-
analog conversion.
To generate this code, we start with all zeros and subsequently change the LSB that will produce
a new value. Gray code is an unweighted code which not suitable for arithmetic operations. Only
one bit in the code group changes when going from one step to the next.
Table 1.1. showing the decimal equivalent of BCD, Excess-3 and Gray in one table
Deci BCD Excess Gray-
mal – three code
0 0000 0011 0000
1 0001 0100 0001
2 0010 0101 0011
3 0011 0110 0010
4 0100 0111 0110
5 0101 1000 0111
6 0110 1001 0101
7 0111 1010 0100
8 1000 1011 1100
9 1001 1010 1101 34
The American Standard Code for Information Interchange (ASCII) Code

Digital computers use alphanumeric codes, that is, codes consisting of both alphabetic
and numeric characters. The ASCII code is the most widely accepted. It was proposed
by the American National Standards Institute (ANSI). The table that is shown below is
referred to as seven-bit ASCII and represents 128 (27) characters assigned to numbers,
letters, punctuation marks, and the most special characters. The standard 7-bit
character representation with the high-order bit and the low-order bit is shown in table
35
below.
Figure 1.5. ASCII table (source: google image). 36
As an example, the bit representation of the letter j is
b7 b6 b5 b4 b3 b2 b1
1 1 0 1 0 1 0

Example
Express the word mov 0xH6 in ASCII code

Solution:

37
Signed and Unsigned number representation and their arithmetic operations
Digital systems, such as computers, must handle both positive and negative numbers.
When working with any kind of digital electronics in which numbers are being
represented, it is important to understand the different ways numbers are represented in
these systems. Almost without fail, numbers are represented by two voltage levels which
can represent a one or a zero.

Signed Number Representation

In ordinary usage, one uses a minus sign to designate a negative integer. However, a
computer can only store information in bits, which can only have the values zero or one.
We might expect, therefore, that the storage of negative numbers in a computer might
require some special technique. Up until now, we've treated the left-most bit (what is
known in these representations as the most-significant bit), as simply another number
when calculating the decimal value of a binary representation. This is fine, assuming that
the number is consider unsigned.

38
Signed Number Representation (Contd.)

However, if the number is considered signed, the most significant bit (MSB) takes on extra
meaning.
1.If the MSB is a 0, we can evaluate the number just as we would any normal unsigned integer,
as we had in the previous part.
However, if the MSB is a 1, this indicates that the number is negative.
How do we evaluate a signed number with a 1 as the left-most bit? It depends on what signed
number representation the number is represented in. The following are different ways of
representing signed number:
Sign - magnitude
One's complement
Two's complement
Of these, the 2's complement is the most important and the sign-magnitude is rarely used.
39
Sign-Magnitude Form

For example, if we wanted to represent the number 41 using 7 bits along with an
additional bit that is the sign bit (to give a total of 8 bits), we would represent it by
00101001. The first bit is a 0, meaning the number is positive, then the remaining 7 bits
give 41, meaning the number is +41. If we wanted to make -59, this would be 10111011.
The first bit is a 1, meaning the number is negative, and then the remaining 7 bits
represent 59, meaning the number is -59.
But what about 10000000? That converts to -0. And 00000000 is +0. Since -0 and +0 are
both just 0, it is very strange to have two different representations for the same number.

40
The Sign Bit
❑ The left-most bit in a signed binary number is the sign bit, which tells you whether the
number is positive or negative.
❑ a 0 is for positive, and
❑ a 1 is for negative
Sign-Magnitude Form
❑ When a signed binary number is represented in sign-magnitude, the left-most bit is the sign bit
and the remaining bits are the magnitude bits.
❑ The magnitude bits are in true (uncomplemented) binary for both positive and negative
numbers.
❑ For example, the decimal number +25 is expressed as an 8-bit signed binary number using
the sign-magnitude form as
00011001

Sign bit Magnitude bits


❑ The decimal number −25 is expressed as 10011001
❑ Notice that the only difference between +25 and -25 is the sign bit because the magnitude bits are in true
binary for both positive and negative numbers
❑ In the sign-magnitude form, a negative number has the same magnitude bits as the corresponding positive
number but the sign bit is a 1 rather than a zero. 41
1’S AND 2’S COMPLEMENTS OF BINARY NUMBERS

❑ The 1's complement and the 2's complement of a binary number are important because they
permit the representation of negative numbers.

❑ The method of 2's complement , arithmetic is commonly used in computers to handle negative
numbers.

Finding the 1's Complement of a Binary Number

❑ The 1's complement of a binary number is found by changing all 1s to 0s and all
0s to 1s, illustrated below:

10110010 Binary number

      

01001101 1’s complement


42
Finding the 2's Complement of a Binary Number
❑The 2's complement of a binary number is found by adding 1 to the LSB
of the 1's complement.
2's complement = (1’s complement) + 1
Example
Find the 2's complement of 10110010.
Solution
10110010 Binary number
01001101 1's complement
+ 1 Add 1
01001110 2's complement
43
TWO’s Complement Way:

When computing the 2's complement of a number it is necessary to know how many bits
are to be used in the final result; leading zeroes will be appended to the most significant
bit in order to make the number the appropriate length.
The 2's (or 1's) complement system for representing signed numbers works like this:
•If the number is positive, the magnitude is represented in its true binary form and a sign
bit 0 is placed in front of the MSB.
•If the number is negative, the magnitude is represented in its complement form and a
sign bit 1 is placed in front of the MSB, i.e., to represent the numbers in sign 2's
complement form, determine the 2's complement of the magnitude of the number and
then attach the sign bit.
44
The 2's complement of a number can be obtained in the following three ways:
Method 1: by obtaining the 1's complement of the given number (by changing all 0s to 1s
and 1s to 0s) and then adding 1.
Method 2: by subtracting the given n-bit number N from 2n.
Method 3: starting at the LSB, copying down each bit up to and including the first 1 bit
encountered, and complementing the remaining bits.
Example
Express -45 in 8-bit 2’s complement form
Solution: +45 in 8-bit form is 00101101

45
Arithmetic operations of signed numbers:

There are four cases that must be considered when adding two numbers:
1.Both numbers positive
2.Positive number and smaller negative number
3.Positive number and larger negative number
Both numbers negative
46
We will take one case at a time. Eight bits are used to represent each number

a. Both numbers positive:


•In this case, both sign bits are zero and a 2's compliment is not required. To illustrate,
we will add +7 and +4:

b. Positive number and smaller negative number:


•In this case, the true binary form of the positive number is added to the 2's complement
of the negative number.
•The sign bits are included in the addition, and the result will be positive. To illustrate we
will add + 15 and -6:
47
Notice that the sign of the sum is positive (0) as it should be.
•Positive number and larger negative number:
•Again, the true binary form of positive number is added to the 2's complement of the
negative number.
•The sign bits are included in the addition, and the result will be negative. To illustrate we
will add + 16 and - 24:

Also, notice that the result automatically comes out in 2's complement because it is a
48
negative number.
•Both numbers negative:
•In this case, the 2's complements of both numbers added and, of course, the sum is a
negative number in 2's complement form illustrate, we will add - 5 and -9:

Note that, in order to convert a two's complement represented number (including


arithmetic results) back to decimal, we need to know whether the number we are
looking at is positive or negative. For positive numbers, we can simply convert the
binary number back to decimal. But for negative numbers, we first need to convert it
back to a normal binary number by applying one of the methods of getting two’s
49
complement.
END!

50

You might also like