Chapter 1 Introduction to Computer Science AP Computer Science Chapter 1 Introduction to Computer Science
1.1 Through 1.4 Nothing in life is obvious Computers are faster, more accurate, and don’t forget information What to do? Ask questions, listen to explanations (maybe more than once), read, practice and give effort
What else requires effort??????? Basketball, football, driving… This results in success
How do we succeed in APCS? Listen to teacher notes Reading chapter-Reading Quiz Getting help from another Type in program examples Observe the results Change some of the statements Observe what happens **Practice on your own-REREAD
What doesn’t work in APCS Cramming Having someone else do your work Copying assignments Getting excessive help **Suggestions from past students
Chapter 1 Lessons 1.5 Morse code, short and long signals (no record of signal, can miss pauses in between) **“Objects First” Activity
Lessons 1.6 Electronic memory uses on/off Magnetic hard drives have on/off 8 light bulbs create 256 different combinations (use 0 for off, 1 for on) Off,on,off,off,off,off,off,on 0 1 0 0 0 0 0 1 (8 bits = 1 byte)
Numbers in base ten and base two Base ten consists of numbers 0,1,2,3,4,5,6,7,8,9 then uses two digits like 10,11, Base two consists of numbers 0,1 then uses two digits like 10,11,
Base ten and Base two (on board) 2 x 102 + 6 x 101 + 1 x 100 101 base 2 = 1 x 22 + 0 x 21 + 1 x 20 = 5 base 10 **Extra practice 10 to 2; 2 to 10
Bits, bytes, and codes A single bulb can be on or off which is called a binary digit or bit (originally one vacuum tube) Eight lights or bits is a byte 1 byte can only represent 256 characters 11111111 (ASCII) 2 bytes is used for Unicode or 65,536 characters **Bit competition
Memory and Storage 1.7 Operating System provides user interface and manages CPU Motherboard – main board consisting of chips of silicon RAM – stores information temporarily (Random Access Memory) ROM – store permanent information (Read Only Memory) CPU – brains of the computer (Central Processing Unit)
Memory is measured in bytes KB–KiloByte 1,024 or 210 MB–MegaByte (1,048,576) or 220 GB–Gigabyte(1,073,741,824) or 230 TB-Terabyte(1,099,511,627,776)240 PB EB **Hw. Ex. 1.1-1.7
Secondary Storage 1.8/1.9 Hard drives, diskettes, tapes, CDs Tapes and disks store iron oxide particles that are magnetically charged + or – CDs are coded with areas that reflect and absorb light Hardware vs. software **Hw. 1.08-1.09
Programming 1.10 Program – lists a sequence of instructions that allows the computer to perform a desired task **Robot activity **Algorithms-driving instructions
1.10 Programming Languages Assembly language used mnemonics for instructions ex. Mov AX,1234 also used Hexidecimal Java is Object Oriented Programming (OOP) Originally called OAK released as Java in 1995 and used in APCS 2003 *Can run on any platform and compatible with web pages Python CS2
Lesson 1.11 Grace Hopper-Navy lieutenant who developed COBOL Low-level and High-level Languages FORTRAN – first successful programming language for the math and science community BASIC –college students Pascal, C, OOP
Other Languages, Hardware, Software C++ - OOP and old way Python in College/next year Read on your own about networking
Some Key Events in Computer History 1842, Ada Lovelace designs programs that work on Charles Babbage’s analytical machine 1954, Fortran (Formula Translator) invented and is first commercially successful programming language for engineers and mathematicians 1958/1962 First video game called Tennis for Two. 1959, COBOL (Common Business Oriented Language) Grace Hopper 1979, Visicalc, Wordstar 1981, MS-DOS, Microsoft
Base sixteen or hexidecimal 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F Any group of 4 base-2 digits corresponds to one base-16 digit 1111 base 2 = F base 16 Base conversions practice and quiz **Hw. 1.10-1.12 F F = 1111 1111