Binary
A bit about Binary
125310^3+2X10^2+510^1+3X10^0 thats the decimal system
for computers, use binary system
1 bit = (a one or a zero) its a magnet polarized one way or another,
or high voltage low voltage, etc.
1 byte = 8 bits (can represent from 0-255)
1 kilobyte = 10^3 9Data Transfer/Disk Storage or 2^10 bytes
Random Access Memory
1 megabyte = 10^6 or 2^20 bytes
etc
237-we have 0 and 1 and powers of two =
0b111(1X2^5)0(0X2^4)1(1X2^3)1(1X2^2)0 (0X2^1)1(1 X2^0)
or even base 16, so =0XED (hexadecimal) A=10, B=11, C=12, D=13,
E=14, F=15
ASCII
Hard Drives
can see this online
hard drives (uses a magnetic disk, polarized as north or south0 or
1 and spins around like a record, interprets these)cost less,
carries more data v. Solid state drives (more complicated, have
transistors-devices kind of like amplifiers, one input and another
input, and decide how big you want the outputwant on or off,
voltage or not)much faster, more durable, less noise
Computer Overview
Start off with Hard Disk/Solid sTAte Drive gets sreamed in 1s
and 0s random access memory (much faster and when turn off,
data all gone, but on hard drive stores it all) goes into
central processing unitget ur fav internet meme
History of C++
Calculating ToolsAbacus, Fullers Slide Rule, Calculating
Drum (based on Napiers Bones) Leonardo da Vinci, Thomas
de Colmars arithmometer, and Phillip Mattaus HahnPart of
Analytical Engine (1830s) (Charles Babbage) go beyond simple
add/sub/mult/div etc. it could now decidePunch cards, an
idea adopted from looms
Theoretical model for computeres: 1936 Turing Machine
computer capable of executing any algorithm, any operations
Data on a tape , a head that reads and writes data on
tape, a state register piece of info that controls how the
machine will work at a given instant, a table of instructions.
Given state and data read by the head, an instruction can:
rewrite datat
move the head
assume a new state
Depite its simplicity, it can do any algorithm
Effective for solving problems in theory of computation