COMPSCI 230 Lecture Notes - Lecture 3: George Boole, Gnu Compiler Collection, Dd National

30 views2 pages

Document Summary

B&se 10 represent&tion&l 12 - 1*10^1 + 2*10^0. Sequence of 8 bits : byte, 4 bits: nibble. 16 digits: 0 - 9 a - f. Convert bin&ry to hex by splitting in groups of 4 bits. P&d the numbers in bin with 0 if they &re not reqd - 0010 (4) 1 + 1 = 10 (1 is c&rry) 1 + 1 + 1 = 11 (1 is c&rry) Neg&tive bin&ry - set the sign(first) bit to 1 &nd le&ve &ll the others unch&nged. Complement - 1 s complement - invert *ll the bits. 2 s complement method - invert &ll the bits then &dd 1, if the &ddition c&use & c&rry on disc&rd th&t shit. For &n unsigned number: overflow h&ppens when the l&st c&rry c&n not be. For & signed number, overflow h&ppens when the most signific&nt bit is not the s&me &s every bit to its left. C d&t& types: unsigned int, singed int, ch&r&cters, flo&ts, doubles.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers