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

Slides:



Advertisements
Similar presentations
Number Systems Discussion D4.1 Appendix C. Number Systems Counting in Binary Positional Notation Hexadecimal Numbers Negative Numbers.
Advertisements

Binary Representation Introduction to Computer Science and Programming I Chris Schmidt.
Copyright © 2008 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Fluency with Information Technology Third Edition by Lawrence Snyder Chapter.
Assembly Language for Intel-Based Computers, 4th Edition
Number Representation (1) Fall 2005 Lecture 12: Number Representation Integers and Computer Arithmetic.
Number System and Codes
Introduction to Number Systems
Number Systems.
ECE 2110: Introduction to Digital Systems Signed Number Conversions.
The College of Saint Rose CIS 433 – Programming Languages David Goldschmidt, Ph.D. from Concepts of Programming Languages, 9th edition by Robert W. Sebesta,
1 Number SystemsLecture 8. 2 BINARY (BASE 2) numbers.
COMPSCI 210 Semester Tutorial 1
Hudson Valley Community College CISS-110 – Programming & Logic I David Goldschmidt, Ph.D.
CSE 111 Representing Numeric Data in a Computer Slides adapted from Dr. Kris Schindler.
The College of Saint Rose CIS 111 – Introduction to Computer Science David Goldschmidt, Ph.D. from Fluency with Information Technology, 4th edition by.
Computing Theory – F453 Number Systems. Data in a computer needs to be represented in a format the computer understands. This does not necessarily mean.
1 Digital Design: Number Systems Credits : Slides adapted from: J.F. Wakerly, Digital Design, 4/e, Prentice Hall, 2006 C.H. Roth, Fundamentals of Logic.
Number Systems. Today Decimal Hexadecimal Binary –Unsigned Binary –1’s Complement Binary –2’s Complement Binary.
Number Systems Ron Christensen CIS 121.
The Teacher CP4 Binary and all that… CP4 Revision.
Chapter 2: The Logic of Compound Statements 2.5 Application: Number Systems and Circuits for Addition 1 Counting in binary is just like counting in decimal.
Data Basics. Binary Number System Numeration systems are methods of representing numbers. All current number systems are positional in nature. In
The College of Saint Rose CIS 521 / MBA 541 – Introduction to Internet Development David Goldschmidt, Ph.D. selected material from Fluency with Information.
Positional Number Systems
Lecture 2 Binary Values and Number Systems. The number 943 is an example of a number written in positional notation. The relative positions of the digits.
Converting From decimal to Binary & Hexadecimal to Binary
The College of Saint Rose CSC 460 / CIS 560 – Search and Information Retrieval David Goldschmidt, Ph.D. from Search Engines: Information Retrieval in Practice,
The Teacher CP4 Binary and all that… CP4 Revision.
Number Systems Binary to Decimal Octal to Decimal Hexadecimal to Decimal Binary to Octal Binary to Hexadecimal Two’s Complement.
AP Computer Science A – Healdsburg High School 1 Unit 1 - Binary Numbers - Hexadecimal Numbers.
Chapter 2 Number Systems: Decimal, Binary, and Hex.
Chapter 2 Bits, Data Types, and Operations. 2-2 Hexadecimal Notation It is often convenient to write binary (base-2) numbers as hexadecimal (base-16)
Hexadecimal Data Representation. Objectives  Know how the Hexadecimal counting system works  Be able to convert between denary, binary & hexadecimal.
Lecture 1: 8/27/2002CS170 Fall CS170 Computer Organization and Architecture I Ayman Abdel-Hamid Department of Computer Science Old Dominion University.
Introduction to Microprocessors Chapter 2. Decimal or Base 10 Numbers  Have ten different digits (0-9)  It is a weighted number system. Each position.
Irvine, Kip R. Assembly Language for Intel-Based Computers 6/e, Signed Integers The highest bit indicates the sign. 1 = negative, 0 = positive.
Number Systems by Dr. Amin Danial Asham. References  Programmable Controllers- Theory and Implementation, 2nd Edition, L.A. Bryan and E.A. Bryan.
Computer Science I CSCI Summer 2009 David E. Goldschmidt, Ph.D.
NUMBER SYSTEMS.
© 2010 Pearson Prentice Hall. All rights reserved. CHAPTER 4 Number Representation and Calculation.
Lecture 2: 8/29/2002CS149D Fall CS149D Elements of Computer Science Ayman Abdel-Hamid Department of Computer Science Old Dominion University Lecture.
Cis303a_chapt03_exam1_answer.ppt CIS303A: System Architecture Exam 1: Chapter 3 Answer List the characters (digits) for the following bases. 1) Decimal:
CS 125 Lecture 3 Martin van Bommel. Overflow In 16-bit two’s complement, what happens if we add =
Lecture No. 4 Computer Logic Design. Negative Number Representation 3 Options –Sign-magnitude –One’s Complement –Two’s Complement  used in computers.
The Hexadecimal System is base 16. It is a shorthand method for representing the 8-bit bytes that are stored in the computer system. This system was chosen.
CMSC 1041 Binary / Hex Binary and Hex The number systems of Computer Science.
Chapter 5 NUMBER REPRESENTATION AND ARITHMETIC CIRCUITS.
Topic: Binary Encoding – Part 1
CSCI 198: Lecture 4: Data Representation
Computer programming {weeks 01 and 02}
CSCI 161: Lecture 4: Data Representation
2.0 COMPUTER SYSTEM 2.2 Number System and Representation
COUNTING IN BINARY Binary weightings 0 x x x x 8
Number Systems Base 2, 10, 16.
Principles of Computing – UFCFA Lecture-3
Introduction to Computer Science
Binary / Hex Binary and Hex The number systems of Computer Science.
Binary Lesson 3 Hexadecimal
Binary Lesson 8a IPv6 Addresses: Hexadecimal
Binary Lesson 3 Hexadecimal
Binary Lesson 3 Hexadecimal
Binary Lesson 8 IPv6 Addresses: Hexadecimal
Binary Lesson 3 Hexadecimal
Binary Lesson 4 Hexadecimal and Binary Practice
COUNTING IN BINARY Binary weightings 0 x x x x 8
Binary Addition (1 of 2) Two 1-bit values A B A + B 1
Binary Lesson 4 Hexadecimal and Binary Practice
Counting to 100 Counting by ones
Lecture 36 – Unit 6 – Under the Hood Binary Encoding – Part 2
Presentation transcript:

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

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

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

 We use ten symbols to count  Digits:  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?

 The powers of 2 give us the decimal weights  Convert from binary to decimal:  in decimal is = 153  What about negative numbers? powers of decimal weights binary digits

 Use two’s complement representation for negative numbers  Convert from binary to decimal:  in decimal is = -103 powers of decimal weights binary digits

 Hexadecimal is base 16  It uses 16 digits: A B C D E F  Why use hex?  Binary numbers are too long  What’s 2BAD in decimal? decimalbinaryhexadecimal A B C D E F

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