SlideShare a Scribd company logo
1 of 23
+
Dr Ramadan Babers
Faculty of Science - Helwan University
Fall – 2018
Introduction
to
Computer
LEC - 2
+
Data Representation
2
Chapter 2 Outlines
 Introduction
 Numbering Systems
 Binary Logic
 Representing Characters
3
2.1 Introduction
4
 Computer systems operate using two voltage
levels (usually 0 volt and +5 volt).
 With two such levels, we can represent exactly two
different values, zero and one.
 All kinds of information processed by the computer
are expressed using only these two values.
2.2 Numbering Systems
2.2.1 Overview of the Decimal Numbering System
5
 We use the decimal system, also called base 10, because
we have ten fingers.
 In decimal, a numeric quantity is represented by a series of
digits from 0 to 9.
2.2 Numbering Systems
2.2.2 The Binary Numbering System
6
 The binary numbering system is a base 2 numbering
system.
 A “binary digit” is called a bit.
2.2 Numbering Systems
2.2.2 The Binary Numbering System
7
 Four bits can represent 16 different values.
 If we use them to represent unsigned integers, we
obtain the range 0 (0000) to 15 (1111).
 In general, n bits can represent the 2n unsigned
integers 0 to 2n-1.
 For example 8 bits (one byte) can represent the
numbers from 0 (00000000) to 255 (11111111).
2.2 Numbering Systems
2.2.2 The Binary Numbering System
8
2.2.2.1 Conversions between Binary and Decimal Systems
 write successive powers of 2 over each digit from
right to left and add up those numbers that are
under a 1.
2.2 Numbering Systems
2.2.2 The Binary Numbering System
9
2.2.2.1 Conversions between Binary and Decimal Systems
 To convert from decimal to binary, divide the
number by two. The remainder (which will be either
0 or 1) is the rightmost binary digit.
2.2 Numbering Systems
2.2.3 Hexadecimal Numbering System
10
 Hexadecimal numbers have two advantages:
they are very compact (short) and it is simple to
convert them to binary and vice versa. Since the
base of a hexadecimal number is 16, each
hexadecimal digit can represent one of sixteen
values between 0 and 15.
2.2 Numbering Systems
2.2.3 Hexadecimal Numbering System
11
2.2.3.1 Decimal to Hexadecimal Conversion
2.2 Numbering Systems
2.2.3 Hexadecimal Numbering System
12
2.2.3.2 Binary to Hexadecimal Conversion
 As you can see,
hexadecimal numbers are
compact and easy to read.
 In addition, you can easily
convert between
hexadecimal and binary
using the table.
2.3 Binary Logic
2.3.1 Overview
13
 Binary logic is used to build the decision-making
unit in computer systems.
 Decision may consist of a combination of smaller
decisions, each one gives either true (binary value
of 1) or false (binary value of 0) situation.
2.3 Binary Logic
2.3.1 Overview
14
 Truth table of AND logical operator
2.3 Binary Logic
2.3.1 Overview
15
 Truth table of OR logical operator
2.3 Binary Logic
2.3.1 Overview
16
 Truth table of NOT logical operator
1
0
2.3 Binary Logic
2.3.1 Overview
17
 First Condition XOR Second Condition
 XOR operator can be explained as following; final
result is true if the first and the second condition
are different.
2.3 Binary Logic
2.3.1 Binary Logical Operations
18
The following example illustrates how to apply the
logical operations to the binary numbers.
2.4. Representing Characters
19
Each character we wish to use must be assigned a
unique binary code or number to distinguish it from all
other characters.
There are two coding systems:
1- The ASCII code
2- The Unicode.
20
ASCII (American Standard Code for Information
Interchange).
We have different characters as:
 Upper-case (A-Z),
 lower-case (a-z),
 numerals (0-9),
 punctuation (, . ; : etc.) and
 control characters (non-printing, e.g. Esc)
2.4. Representing Characters
2.4.1 ASCII Codes (8-bit)
21
The following table shows the ASCII table, showing
the codes used for all different characters.
2.4. Representing Characters
2.4.1 ASCII Codes (8-bit)
22
Note that upper and lower cases of a letter differ only
in bit 5 making case-conversion easy:
 To change from lower-to-upper: set bit 5 = 0
 To change from upper to lower: set bit 5 = 1
 To change case: invert bit 5
2.4. Representing Characters
2.4.1 ASCII Codes (8-bit)
23
 The problem with ASCII codes is that a maximum of 256 (8-
bit) characters can be represented.
 Needed for other languages such as Chinese or Japanese
where there are literally thousands of individual characters
making up the language alphabet.
 Unicode allows more than 65,000 characters to be
represented
 The first 128 Unicode codes correspond to the standard
ASCII codes.
2.4. Representing Characters
2.4.2 Unicode (16-bit)

More Related Content

What's hot

Computers numbering systems
Computers   numbering systemsComputers   numbering systems
Computers numbering systemssld1950
 
Topic 1 Data Representation
Topic 1 Data RepresentationTopic 1 Data Representation
Topic 1 Data Representationekul
 
B sc cs i bo-de u-iii combitional logic circuit
B sc cs i bo-de u-iii combitional logic circuitB sc cs i bo-de u-iii combitional logic circuit
B sc cs i bo-de u-iii combitional logic circuitRai University
 
Logic design and switching theory
Logic design and switching theoryLogic design and switching theory
Logic design and switching theoryjomerson remorosa
 
More on number system
More on number systemMore on number system
More on number systemsamina khan
 
Chapter 1 number and code system sss
Chapter 1 number and code system sssChapter 1 number and code system sss
Chapter 1 number and code system sssBaia Salihin
 
Binary ,octa,hexa conversion
Binary ,octa,hexa conversionBinary ,octa,hexa conversion
Binary ,octa,hexa conversionChaudharyShoaib7
 
Data repersentation.
Data repersentation.Data repersentation.
Data repersentation.Ritesh Saini
 
Variables in Visual Basic Programming
Variables in Visual Basic ProgrammingVariables in Visual Basic Programming
Variables in Visual Basic ProgrammingKasun Ranga Wijeweera
 
Data representation
Data representationData representation
Data representationManish Kumar
 
DCN Error Detection & Correction
DCN Error Detection & CorrectionDCN Error Detection & Correction
DCN Error Detection & CorrectionRohan Bhatkar
 
Computer data representation (integers, floating-point numbers, text, images,...
Computer data representation (integers, floating-point numbers, text, images,...Computer data representation (integers, floating-point numbers, text, images,...
Computer data representation (integers, floating-point numbers, text, images,...ArtemKovera
 

What's hot (20)

Computers numbering systems
Computers   numbering systemsComputers   numbering systems
Computers numbering systems
 
Chapter 1: Binary System
 Chapter 1: Binary System Chapter 1: Binary System
Chapter 1: Binary System
 
Quantitative Analysis 2
Quantitative Analysis 2Quantitative Analysis 2
Quantitative Analysis 2
 
Topic 1 Data Representation
Topic 1 Data RepresentationTopic 1 Data Representation
Topic 1 Data Representation
 
Basics of digital electronics
Basics of digital electronicsBasics of digital electronics
Basics of digital electronics
 
Data Representation
Data RepresentationData Representation
Data Representation
 
B sc cs i bo-de u-iii combitional logic circuit
B sc cs i bo-de u-iii combitional logic circuitB sc cs i bo-de u-iii combitional logic circuit
B sc cs i bo-de u-iii combitional logic circuit
 
Logic design and switching theory
Logic design and switching theoryLogic design and switching theory
Logic design and switching theory
 
More on number system
More on number systemMore on number system
More on number system
 
Chapter 1 number and code system sss
Chapter 1 number and code system sssChapter 1 number and code system sss
Chapter 1 number and code system sss
 
Binary ,octa,hexa conversion
Binary ,octa,hexa conversionBinary ,octa,hexa conversion
Binary ,octa,hexa conversion
 
Data repersentation.
Data repersentation.Data repersentation.
Data repersentation.
 
Variables in Visual Basic Programming
Variables in Visual Basic ProgrammingVariables in Visual Basic Programming
Variables in Visual Basic Programming
 
Data representation
Data representationData representation
Data representation
 
Binary Codes
Binary CodesBinary Codes
Binary Codes
 
DCN Error Detection & Correction
DCN Error Detection & CorrectionDCN Error Detection & Correction
DCN Error Detection & Correction
 
Data representation
Data representationData representation
Data representation
 
Number system
Number system Number system
Number system
 
Dld lecture notes
Dld lecture notesDld lecture notes
Dld lecture notes
 
Computer data representation (integers, floating-point numbers, text, images,...
Computer data representation (integers, floating-point numbers, text, images,...Computer data representation (integers, floating-point numbers, text, images,...
Computer data representation (integers, floating-point numbers, text, images,...
 

Similar to Introduction to computer_lec_02_fall_2018

Number system and conversions between different number systems
Number system and conversions between different number systemsNumber system and conversions between different number systems
Number system and conversions between different number systemswafaashalash
 
Presentation of ICT.ppt.pptx
Presentation of ICT.ppt.pptxPresentation of ICT.ppt.pptx
Presentation of ICT.ppt.pptxMinahilUmar1
 
Ch 02 Encoding & Number System.pdf
Ch 02 Encoding & Number System.pdfCh 02 Encoding & Number System.pdf
Ch 02 Encoding & Number System.pdfA23AyushRajBaranwal
 
Digital Electronics- Number systems & codes
Digital Electronics- Number systems & codes Digital Electronics- Number systems & codes
Digital Electronics- Number systems & codes VandanaPagar1
 
Lecture_Computer_Codes.ppt
Lecture_Computer_Codes.pptLecture_Computer_Codes.ppt
Lecture_Computer_Codes.pptMarlonMagtibay2
 
Manoch1raw 160512091436
Manoch1raw 160512091436Manoch1raw 160512091436
Manoch1raw 160512091436marangburu42
 
12.Representation of signed binary numbers. Binary codes - BCD code, Gray co...
12.Representation of signed binary numbers.  Binary codes - BCD code, Gray co...12.Representation of signed binary numbers.  Binary codes - BCD code, Gray co...
12.Representation of signed binary numbers. Binary codes - BCD code, Gray co...JatinJatin30
 
Dee 2034 chapter 1 number and code system (Baia)
Dee 2034 chapter 1 number and code system (Baia)Dee 2034 chapter 1 number and code system (Baia)
Dee 2034 chapter 1 number and code system (Baia)SITI SABARIAH SALIHIN
 
Introduction to digital computers and Number systems.pptx
Introduction to digital computers and Number systems.pptxIntroduction to digital computers and Number systems.pptx
Introduction to digital computers and Number systems.pptxBhawaniShankarSahu1
 
numbersystem-211022083557.pdf
numbersystem-211022083557.pdfnumbersystem-211022083557.pdf
numbersystem-211022083557.pdfAsthaChaurasia4
 
FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...
FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...
FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...Arti Parab Academics
 

Similar to Introduction to computer_lec_02_fall_2018 (20)

Number system and conversions between different number systems
Number system and conversions between different number systemsNumber system and conversions between different number systems
Number system and conversions between different number systems
 
Presentation of ICT.ppt.pptx
Presentation of ICT.ppt.pptxPresentation of ICT.ppt.pptx
Presentation of ICT.ppt.pptx
 
Csc 2313 (lecture 3)
Csc 2313 (lecture 3)Csc 2313 (lecture 3)
Csc 2313 (lecture 3)
 
Csc 2313 (lecture 3)
Csc 2313 (lecture 3)Csc 2313 (lecture 3)
Csc 2313 (lecture 3)
 
Number system
Number systemNumber system
Number system
 
1.1.1 BINARY SYSTEM
1.1.1 BINARY SYSTEM1.1.1 BINARY SYSTEM
1.1.1 BINARY SYSTEM
 
NUMBER SYSTEM.pptx
NUMBER SYSTEM.pptxNUMBER SYSTEM.pptx
NUMBER SYSTEM.pptx
 
Ch 02 Encoding & Number System.pdf
Ch 02 Encoding & Number System.pdfCh 02 Encoding & Number System.pdf
Ch 02 Encoding & Number System.pdf
 
Chap02_1473751047_598100.ppt
Chap02_1473751047_598100.pptChap02_1473751047_598100.ppt
Chap02_1473751047_598100.ppt
 
Digital Electronics- Number systems & codes
Digital Electronics- Number systems & codes Digital Electronics- Number systems & codes
Digital Electronics- Number systems & codes
 
Lecture_Computer_Codes.ppt
Lecture_Computer_Codes.pptLecture_Computer_Codes.ppt
Lecture_Computer_Codes.ppt
 
Chapter 3.pptx
Chapter 3.pptxChapter 3.pptx
Chapter 3.pptx
 
Number system
Number systemNumber system
Number system
 
Manoch1raw 160512091436
Manoch1raw 160512091436Manoch1raw 160512091436
Manoch1raw 160512091436
 
12.Representation of signed binary numbers. Binary codes - BCD code, Gray co...
12.Representation of signed binary numbers.  Binary codes - BCD code, Gray co...12.Representation of signed binary numbers.  Binary codes - BCD code, Gray co...
12.Representation of signed binary numbers. Binary codes - BCD code, Gray co...
 
Dee 2034 chapter 1 number and code system (Baia)
Dee 2034 chapter 1 number and code system (Baia)Dee 2034 chapter 1 number and code system (Baia)
Dee 2034 chapter 1 number and code system (Baia)
 
Introduction to digital computers and Number systems.pptx
Introduction to digital computers and Number systems.pptxIntroduction to digital computers and Number systems.pptx
Introduction to digital computers and Number systems.pptx
 
Computer Number system
Computer Number systemComputer Number system
Computer Number system
 
numbersystem-211022083557.pdf
numbersystem-211022083557.pdfnumbersystem-211022083557.pdf
numbersystem-211022083557.pdf
 
FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...
FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...
FYBSC IT Digital Electronics Unit I Chapter I Number System and Binary Arithm...
 

More from Ramadan Babers, PhD

Part10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysisPart10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysisRamadan Babers, PhD
 
Part09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratioPart09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratioRamadan Babers, PhD
 
Part08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratioPart08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratioRamadan Babers, PhD
 
Part07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratioPart07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratioRamadan Babers, PhD
 
Part06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratioPart06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratioRamadan Babers, PhD
 
Part05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentationPart05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentationRamadan Babers, PhD
 
Part04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentationPart04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentationRamadan Babers, PhD
 
Part03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentationPart03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentationRamadan Babers, PhD
 
Part02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentationPart02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentationRamadan Babers, PhD
 
Part01 finance investment_basics_presentation
Part01 finance investment_basics_presentationPart01 finance investment_basics_presentation
Part01 finance investment_basics_presentationRamadan Babers, PhD
 
Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0Ramadan Babers, PhD
 
Classification using decision tree in detail
Classification using decision tree in detailClassification using decision tree in detail
Classification using decision tree in detailRamadan Babers, PhD
 

More from Ramadan Babers, PhD (20)

Part10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysisPart10 finance investment limitations of ratio analysis
Part10 finance investment limitations of ratio analysis
 
Part09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratioPart09 finance investment ratio analysis investment ratio
Part09 finance investment ratio analysis investment ratio
 
Part08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratioPart08 finance investment ratio analysis solvency ratio
Part08 finance investment ratio analysis solvency ratio
 
Part07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratioPart07 finance investment ratio analysis profitability ratio
Part07 finance investment ratio analysis profitability ratio
 
Part06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratioPart06 finance investment ratio analysis efficiency ratio
Part06 finance investment ratio analysis efficiency ratio
 
Part05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentationPart05 finance investment_ratio_analysis_liquidity_ratio_presentation
Part05 finance investment_ratio_analysis_liquidity_ratio_presentation
 
Part04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentationPart04 finance investment_ratio_analysis_introduction_presentation
Part04 finance investment_ratio_analysis_introduction_presentation
 
Part03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentationPart03 finance investment_financial_statement_analysis_presentation
Part03 finance investment_financial_statement_analysis_presentation
 
Part02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentationPart02 finance investment_finance_and_financial_reporting_presentation
Part02 finance investment_finance_and_financial_reporting_presentation
 
Part01 finance investment_basics_presentation
Part01 finance investment_basics_presentationPart01 finance investment_basics_presentation
Part01 finance investment_basics_presentation
 
Strategic Management part_03_03
Strategic Management part_03_03Strategic Management part_03_03
Strategic Management part_03_03
 
Strategic Management part_02_03
Strategic Management part_02_03Strategic Management part_02_03
Strategic Management part_02_03
 
Strategic Management part_01_03
Strategic Management part_01_03Strategic Management part_01_03
Strategic Management part_01_03
 
Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0Customer Experience (CX) updated version V9.0
Customer Experience (CX) updated version V9.0
 
Classification using decision tree in detail
Classification using decision tree in detailClassification using decision tree in detail
Classification using decision tree in detail
 
Customer Experience (CX)
Customer Experience (CX)Customer Experience (CX)
Customer Experience (CX)
 
Python lec 1004_ch02_excercies
Python lec 1004_ch02_excerciesPython lec 1004_ch02_excercies
Python lec 1004_ch02_excercies
 
Python lec 1003_for_biologists
Python lec 1003_for_biologistsPython lec 1003_for_biologists
Python lec 1003_for_biologists
 
Python lec 1002_for_biologists
Python lec 1002_for_biologistsPython lec 1002_for_biologists
Python lec 1002_for_biologists
 
Python lec 1001_for_biologists
Python lec 1001_for_biologistsPython lec 1001_for_biologists
Python lec 1001_for_biologists
 

Recently uploaded

EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxRaymartEstabillo3
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfakmcokerachita
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Sapana Sha
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfadityarao40181
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentInMediaRes1
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application ) Sakshi Ghasle
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxsocialsciencegdgrohi
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfSumit Tiwari
 
Science lesson Moon for 4th quarter lesson
Science lesson Moon for 4th quarter lessonScience lesson Moon for 4th quarter lesson
Science lesson Moon for 4th quarter lessonJericReyAuditor
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17Celine George
 
Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsKarinaGenton
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfMahmoud M. Sallam
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon AUnboundStockton
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxSayali Powar
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityGeoBlogs
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxiammrhaywood
 
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxAnaBeatriceAblay2
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Celine George
 

Recently uploaded (20)

EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptxEPANDING THE CONTENT OF AN OUTLINE using notes.pptx
EPANDING THE CONTENT OF AN OUTLINE using notes.pptx
 
Class 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdfClass 11 Legal Studies Ch-1 Concept of State .pdf
Class 11 Legal Studies Ch-1 Concept of State .pdf
 
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111Call Girls in Dwarka Mor Delhi Contact Us 9654467111
Call Girls in Dwarka Mor Delhi Contact Us 9654467111
 
Biting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdfBiting mechanism of poisonous snakes.pdf
Biting mechanism of poisonous snakes.pdf
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
Alper Gobel In Media Res Media Component
Alper Gobel In Media Res Media ComponentAlper Gobel In Media Res Media Component
Alper Gobel In Media Res Media Component
 
Hybridoma Technology ( Production , Purification , and Application )
Hybridoma Technology  ( Production , Purification , and Application  ) Hybridoma Technology  ( Production , Purification , and Application  )
Hybridoma Technology ( Production , Purification , and Application )
 
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptxHistory Class XII Ch. 3 Kinship, Caste and Class (1).pptx
History Class XII Ch. 3 Kinship, Caste and Class (1).pptx
 
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdfEnzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
Enzyme, Pharmaceutical Aids, Miscellaneous Last Part of Chapter no 5th.pdf
 
Science lesson Moon for 4th quarter lesson
Science lesson Moon for 4th quarter lessonScience lesson Moon for 4th quarter lesson
Science lesson Moon for 4th quarter lesson
 
How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17How to Configure Email Server in Odoo 17
How to Configure Email Server in Odoo 17
 
Science 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its CharacteristicsScience 7 - LAND and SEA BREEZE and its Characteristics
Science 7 - LAND and SEA BREEZE and its Characteristics
 
Pharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdfPharmacognosy Flower 3. Compositae 2023.pdf
Pharmacognosy Flower 3. Compositae 2023.pdf
 
Crayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon ACrayon Activity Handout For the Crayon A
Crayon Activity Handout For the Crayon A
 
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptxPOINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
POINT- BIOCHEMISTRY SEM 2 ENZYMES UNIT 5.pptx
 
Paris 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activityParis 2024 Olympic Geographies - an activity
Paris 2024 Olympic Geographies - an activity
 
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptxSOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
SOCIAL AND HISTORICAL CONTEXT - LFTVD.pptx
 
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptxENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
ENGLISH5 QUARTER4 MODULE1 WEEK1-3 How Visual and Multimedia Elements.pptx
 
Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17Computed Fields and api Depends in the Odoo 17
Computed Fields and api Depends in the Odoo 17
 
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝Model Call Girl in Bikash Puri  Delhi reach out to us at 🔝9953056974🔝
Model Call Girl in Bikash Puri Delhi reach out to us at 🔝9953056974🔝
 

Introduction to computer_lec_02_fall_2018

  • 1. + Dr Ramadan Babers Faculty of Science - Helwan University Fall – 2018 Introduction to Computer LEC - 2
  • 3. Chapter 2 Outlines  Introduction  Numbering Systems  Binary Logic  Representing Characters 3
  • 4. 2.1 Introduction 4  Computer systems operate using two voltage levels (usually 0 volt and +5 volt).  With two such levels, we can represent exactly two different values, zero and one.  All kinds of information processed by the computer are expressed using only these two values.
  • 5. 2.2 Numbering Systems 2.2.1 Overview of the Decimal Numbering System 5  We use the decimal system, also called base 10, because we have ten fingers.  In decimal, a numeric quantity is represented by a series of digits from 0 to 9.
  • 6. 2.2 Numbering Systems 2.2.2 The Binary Numbering System 6  The binary numbering system is a base 2 numbering system.  A “binary digit” is called a bit.
  • 7. 2.2 Numbering Systems 2.2.2 The Binary Numbering System 7  Four bits can represent 16 different values.  If we use them to represent unsigned integers, we obtain the range 0 (0000) to 15 (1111).  In general, n bits can represent the 2n unsigned integers 0 to 2n-1.  For example 8 bits (one byte) can represent the numbers from 0 (00000000) to 255 (11111111).
  • 8. 2.2 Numbering Systems 2.2.2 The Binary Numbering System 8 2.2.2.1 Conversions between Binary and Decimal Systems  write successive powers of 2 over each digit from right to left and add up those numbers that are under a 1.
  • 9. 2.2 Numbering Systems 2.2.2 The Binary Numbering System 9 2.2.2.1 Conversions between Binary and Decimal Systems  To convert from decimal to binary, divide the number by two. The remainder (which will be either 0 or 1) is the rightmost binary digit.
  • 10. 2.2 Numbering Systems 2.2.3 Hexadecimal Numbering System 10  Hexadecimal numbers have two advantages: they are very compact (short) and it is simple to convert them to binary and vice versa. Since the base of a hexadecimal number is 16, each hexadecimal digit can represent one of sixteen values between 0 and 15.
  • 11. 2.2 Numbering Systems 2.2.3 Hexadecimal Numbering System 11 2.2.3.1 Decimal to Hexadecimal Conversion
  • 12. 2.2 Numbering Systems 2.2.3 Hexadecimal Numbering System 12 2.2.3.2 Binary to Hexadecimal Conversion  As you can see, hexadecimal numbers are compact and easy to read.  In addition, you can easily convert between hexadecimal and binary using the table.
  • 13. 2.3 Binary Logic 2.3.1 Overview 13  Binary logic is used to build the decision-making unit in computer systems.  Decision may consist of a combination of smaller decisions, each one gives either true (binary value of 1) or false (binary value of 0) situation.
  • 14. 2.3 Binary Logic 2.3.1 Overview 14  Truth table of AND logical operator
  • 15. 2.3 Binary Logic 2.3.1 Overview 15  Truth table of OR logical operator
  • 16. 2.3 Binary Logic 2.3.1 Overview 16  Truth table of NOT logical operator 1 0
  • 17. 2.3 Binary Logic 2.3.1 Overview 17  First Condition XOR Second Condition  XOR operator can be explained as following; final result is true if the first and the second condition are different.
  • 18. 2.3 Binary Logic 2.3.1 Binary Logical Operations 18 The following example illustrates how to apply the logical operations to the binary numbers.
  • 19. 2.4. Representing Characters 19 Each character we wish to use must be assigned a unique binary code or number to distinguish it from all other characters. There are two coding systems: 1- The ASCII code 2- The Unicode.
  • 20. 20 ASCII (American Standard Code for Information Interchange). We have different characters as:  Upper-case (A-Z),  lower-case (a-z),  numerals (0-9),  punctuation (, . ; : etc.) and  control characters (non-printing, e.g. Esc) 2.4. Representing Characters 2.4.1 ASCII Codes (8-bit)
  • 21. 21 The following table shows the ASCII table, showing the codes used for all different characters. 2.4. Representing Characters 2.4.1 ASCII Codes (8-bit)
  • 22. 22 Note that upper and lower cases of a letter differ only in bit 5 making case-conversion easy:  To change from lower-to-upper: set bit 5 = 0  To change from upper to lower: set bit 5 = 1  To change case: invert bit 5 2.4. Representing Characters 2.4.1 ASCII Codes (8-bit)
  • 23. 23  The problem with ASCII codes is that a maximum of 256 (8- bit) characters can be represented.  Needed for other languages such as Chinese or Japanese where there are literally thousands of individual characters making up the language alphabet.  Unicode allows more than 65,000 characters to be represented  The first 128 Unicode codes correspond to the standard ASCII codes. 2.4. Representing Characters 2.4.2 Unicode (16-bit)