Download presentation
Presentation is loading. Please wait.
1
CS120: Lecture 1 MP Johnson Hunter College mpjohnson@gmail.com
2
agenda Admin Syllabus Survey Data, storage, representation
3
admin Sessions: 9:48-11:26am / 11:36-1:14pm HW 224 Class page Email Text OHs tba Grading –Hw (written, prog., labs) – O(6) ~ 45% –Exams – 20% + 25% –Class partic/quizzes – 10% Start or end of class Attendance is required – 80%
4
Core Class topics 1Breadth-first tour of CS 2Data –storage –Representation of knowledge) –Compression (JPG, MP3) 3How computers work –Machines 4networks, Internet, OS 1HTML 2FTP, SSH 5Algorithms – good ones? 6Programming / SE / data structures
5
Advanced/optional AI Hardware Crypto Unsolvable problems Search Engines Social/political issues? Other topics? Some parts of class will be challenging Many will be applied/topical – read Slashdot/Digg
6
Survey 1.Name 2.Email (clearly!!) 3.Grade-level 4.Major 5.Why taking class 6.Topics you’re most interested in
7
Q: What are comps? A: machines that compute Q: compute what? A: the output of some algorithm Alg: list of instructions / recipe –Abstract but unambiguous (how?) –Much more later Egs: long division algorithm, gcd, sorting
8
Long (pre)history Abacus (3000BC) – just storage Pascal (1600s) – addition Leibniz (1600s/1700s) – math Babbage Diff. gin (1800s) – math Babbage An. Gin – punched cards All these were mechanical (gears, etc.) –Difficult to make reliable & fast & cheap
9
20 th C: electronics Circuits, transistors, etc. Mach 1, ENIAC, UNIVAC (1940s) - room-sized Since then: “just” miniaturization Mainframes supercomps, minis PCs (“micros”): early 80s on All “essentially” same: –Run many programs (v. arcade machine) –These programs impl. Algs (tho in diff. langs) –They store, rep, use data
10
Today: data CS = abstraction + reduction –“that’s so reductive” In CS, all data is numbers, All numbers are bits (0/1) / bools (F/T) Bit = binary digit boolean ~ George Boole (1800s)
11
Bool logic/algebra Vals: F, T Ops: and, or, xor, not Draw truth tables Xor intuit: soup or sald Can write exprs Exprs can nest
12
Bool expr eg Suppose A ~ empl A is working, B, C Suppose want: should always be exactly one empl working Q: If we only know bool logic, how to test? Q: how to write a “program” for this in bool logic? (A & ~B & ~C) | … (A xor B) & … (A | B | C) …
13
Q: How to compute/eval this? We now understand bool ops, so we could perform each op ourselves –A gp of female workers in WWII were called “computers” Bad: too slow, error-prone Funda strength of comps: can do some (v. simple) things v. fast
14
strategy Don’t: create a special machine to comp whole expr/function/program Do: create a little machine for each component, then combine –Forget about software for now! How? First, bool ops gates
15
gates
16
Gates elec circuit No one of these is v. interesting But two big insights: –Can create an implement gate electronically 0/1 low/high current –Gates can be combined to produce powerful computations / representations electronic circuits / chips Draw circuits for each expr Of course, want software (non-kickable) For that we need a compiler…
17
Circuits as memory Flipflop: special circuit that can store data –1 bit per FF To store, send pulse in top or bottom (0 is ddf) Go through Reading for next week: wiki entries on boolean logic and two’s complete (through section 2 only)
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.