Presentation is loading. Please wait.

Presentation is loading. Please wait.

The College of Saint Rose CSC 202 – Introduction to Programming David Goldschmidt, Ph.D.

Similar presentations


Presentation on theme: "The College of Saint Rose CSC 202 – Introduction to Programming David Goldschmidt, Ph.D."— Presentation transcript:

1 The College of Saint Rose CSC 202 – Introduction to Programming David Goldschmidt, Ph.D.

2  Hardware consists of five key subsystems: from Fluency with Information Technology, 4th edition by Lawrence Snyder, Addison-Wesley, 2010, ISBN 0-13-609182-2

3  Each instruction goes through this cycle: from Fluency with Information Technology, 4th edition by Lawrence Snyder, Addison-Wesley, 2010, ISBN 0-13-609182-2

4

5

6

7

8

9

10

11  We use ten symbols to count  Digits: 0 1 2 3 4 5 6 7 8 9  Computers use two symbols to count  Digits: 0 1 (why?)  What is the exact mechanism for counting?  How do we count from 1 to 20?

12  The powers of 2 give us the decimal weights  Convert 10011001 from binary to decimal:  10011001 in decimal is 128 + 16 + 8 + 1 = 153  What about negative numbers? powers of 22727 2626 2525 2424 23232 2121 2020 decimal weights1286432168421 binary digits10011001

13  Use two’s complement representation for negative numbers  Convert 10011001 from binary to decimal:  10011001 in decimal is -128 + 16 + 8 + 1 = -103 powers of 2-2 7 2626 2525 2424 23232 2121 2020 decimal weights-1286432168421 binary digits10011001

14  Hexadecimal is base 16  It uses 16 digits: 0 1 2 3 4 5 6 7 8 9 A B C D E F  Why use hex?  Binary numbers are too long  What’s 2BAD in decimal? decimalbinaryhexadecimal 000000 100011 200102 300113 401004 501015 601106 701117 810008 910019 101010A 111011B 121100C 131101D 141110E 151111F

15  Represent printable and special characters  What about Unicode? from Fluency with Information Technology, 4th edition by Lawrence Snyder, Addison-Wesley, 2010, ISBN 0-13-609182-2


Download ppt "The College of Saint Rose CSC 202 – Introduction to Programming David Goldschmidt, Ph.D."

Similar presentations


Ads by Google