Skip to main content

CONVERSION BETWEEN DIFFERENT NUMBER SYSTEM

Conversion Decimal To Binary:
Steps:-
  • Divide the Decimal Number by 2
  • Get the remainder from step 1
  • Divide the quotient of the previous  by 2
  • Record the remainder from step 3.
  • Repeat step 3 and 4 for getting remainder until the quotient become 1 or 0.
  • write the quotient and remainder from last step to first step or from bottom to top.
Ex-  37 = (?)2
Sol:
2
37
R
2
18
1
2
9
0
2
4
1
2
2
0

1
0

(100101)2
Conversion Binary To Decimal:
Steps:-
  • Determine the position value of each digit
  • Multiply the postion value with by the corrosponding power of 2.
  • and Sum is the equivalent value in Decimal.
Ex- (100101)2
=1x25 + 0x24 + 0x23 + 1x22 + 0x21 + 1 x 20
=1x32 + 0x16 + 0x8 + 1x4 + 0x 2 + 1x 1
=32+0+0+4+1
= (37)10
(1011111)2=
= 1x26 + 0x25 + 1x24 + 1x23 + 1x22 + 1x21 + 1x20
=1x64 + 0x32 + 1x16 + 1x8 + 1x4 + 1x2 + 1x1
= 64+0+16+8+4+2+1
= (95)10
Conversion Decimal To Octal:
Steps:-

  • Divide the Decimal Number by 8
  • Get the remainder from step 1
  • Divide the quotient of the previous  by 2
  • Record the remainder from step 3.
  • Repeat step 3 and 4 for getting remainder until the quotient become 0 to 7(mean 0,1,2,3,4,5,6,7).
  • write the cosent and remainder from last step to first step or from bottom to top.
Ex-    
68)10= (?)8
8
68
R
8
8
4

1
0
(104)8
Conversion Octal To Decimal:
Steps:-
  • Determine the position value of each digit
  • Multiply the postion value with by the corrosponding power of 8.
  • and Sum is the equivalent value in Decimal.
Ex- (174)8
=1x82 + 7x81 + 4 x 80
=1x64+7x8+4x1
=64+56+4
= (124)10
Conversion Decimal To HexaDecimal
Steps:-
  • Divide the Decimal Number by 16.
  • Get the remainder from step 1.
  • Divide the quotient of the previous  by 16.
  • Record the remainder from step 3.
  • Repeat step 3 and 4 for getting remainder until the quotient become 0 to15.
  • write the quotient and remainder from last step to first step or from bottom to top.
  • Here Some Changes when we write Numbers, We Use A for 10, B for 11, C for 12, D for 13, E for 14 and F for 15.
Ex-  (813)10=(?)16
Sol:
(813)10= (?)16
16
813
R
16
50
13

3
2

Here The Number Became 32-13 that mean (32D)16.
Conversion Decimal To HexaDecimal:
Steps:-
  • Determine the position value of each digit.
  • Here Some Changes when we write Numbers, We Use A for 10, B for 11, C for 12, D for 13, E for 14 and F for 15.
  • Multiply the postion value with by the corrosponding power of 16.
  • and Sum is the equivalent value in Decimal.
Ex- (3AF)8
=3x162 + Ax161 + F x 160
=3x162 + 10x161 + 15 x 160
=3x256+10x16+15x1
=768+160+15
= (943)10

Comments

Popular posts from this blog

Computer Generations

 Computer Generations   Computers have evolved over time through different generations, each marked by significant technological advancements and changes in design and architecture. These generations are often categorized based on the underlying hardware and the key developments that distinguish one Generation from another. Let's explore the main computer generations: First Generation Computers    The First Generation of computers refers to the initial period of electronic computing, characterized by the use of vacuum tubes as the primary electronic component. This Generation spans the 1940s and 1950s and is marked by groundbreaking developments in computer technology.  Examples of First-Generation Computers:  o ENIAC (Electronic Numerical Integrator and Computer): Completed in 1945, ENIAC was one of the first electronic general-purpose computers. It was designed to calculate artillery firing tables for the United States Army during World War ...

Programming in "C"

 Introduction   C is a general-purpose programming language that was developed in the early 1970s by Dennis Ritchie at Bell Laboratories. It has since become one of the most widely used programming languages and has influenced the development of many other languages, including C++, Java, and C#. C is known for its efficiency, flexibility, and low-level programming capabilities. It is commonly used for system programming, embedded systems, and developing operating systems. C is also a popular choice for developing applications that require high performance, such as game engines and scientific simulations.   Here are some key features and concepts of C programming:   Syntax: C has a relatively simple syntax compared to some other programming languages. It uses a combination of keywords, variables, data types, operators, and control structures to write programs.  Variables and Data Types: You declare variables to store data in C. Various d...

History of Language "C"

  History of C      The history of C programming dates back to the early 1970s when Dennis Ritchie created it at Bell Laboratories. Here's a brief timeline of the major milestones in the history of C:  1969: The development of C began as a successor to the B programming language, which Ken Thompson created. Dennis Ritchie wanted to improve upon B's capabilities and efficiency.  1972: The C programming language was developed primarily to support the development of the Unix operating system. Ken Thompson and Dennis Ritchie rewrote Unix in C, which helped in porting the operating system to different computer architectures easily. 1978: The first edition of "The C Programming Language," also known as the "K&R C," was published. Brian Kernighan and Dennis Ritchie wrote it, becoming the authoritative reference for C programming. 1983: The American National Standards Institute (ANSI) formed a committee to establish a standard for the C language. The ...