![Page 1: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/1.jpg)
CS 127Introduction to Computer Science
![Page 2: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/2.jpg)
What is a computer?
“A machine that stores and manipulates information under the control of a changeable program” [1]
“A computer is a general purpose device that can be programmed to carry out a set of arithmetic or logical operations” [2]
Two key concepts:It is a machineIt can be controlled via instructions[1] Python Programming : An Introduction to Computer Science - Zelle[2] Wikipedia
![Page 3: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/3.jpg)
What is a computer program?
“Detailed step by step instructions telling a computer exactly what to do” [1]
“It is a sequence of instructions, written to perform a specified task with a computer” [2]
Computers simply execute programs or instructions
Without being told what to do, computers would not be useful
Software (programs) rules or controls the hardware (physical machine)[1] Python Programming : An Introduction to Computer Science - Zelle[2] Wikipedia
![Page 4: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/4.jpg)
Programming
The process of creating softwareIt is a challenging
You have to see the big pictureYou have to pay attention to every detail
It is important to learn programming because it is such an integral part of computer science
Allows development of problem solving skillsAllows complex systems to be analyzed and
reduced to interactions and understandable subsystems
4
![Page 5: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/5.jpg)
What is computer science?
“The scientific and practical approach to computation and its applications” [1]
Computers are simply a tool that are used in computer science
Three important conceptsDesignAnalysisExperimentation
5[1] Wikipedia
![Page 6: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/6.jpg)
Design
Formulating a solution to a problemOften involves a step by step process for
achieving a resultAn algorithm
Look at problems in a logical way and design a solution
This is a critical process in computer science
Most time should be spent here to allow for efficiency in the development process 6
![Page 7: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/7.jpg)
Analysis
The process of examining algorithms and problems mathematically
Every algorithm to solve a problem cannot always be implementedLack of computational resourcesNot feasible time-wiseNot enough memory
Analysis of algorithms is important in computer science
The bottom line is whether a working, reliable system can be built 7
![Page 8: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/8.jpg)
Other areas of computer scienceNetworkingHuman-Computer InteractionArtificial IntelligenceComputational Science (using
computers to model scientific data)DatabasesSoftware EngineeringWeb and Multimedia DesignMIS (Management Information Systems)Security 8
![Page 9: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/9.jpg)
Computer Hardware
9
![Page 10: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/10.jpg)
Computer Hardware
Central Processing Unit (CPU) - Brain of the computer
Memory - Stores programs and dataMain Memory (RAM - Random
Access Memory)RAM - Fast and VolatileCache
Secondary Memory or StorageHard Disk DriveOptical Drive - CD, DVD 10
![Page 11: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/11.jpg)
Computer Hardware
Peripheral DevicesKeyboard - InputMouse - InputMonitor - OutputPrinter - Output
11
![Page 12: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/12.jpg)
Computer Hardware
12
![Page 13: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/13.jpg)
Programming Languages
Computers need to be told in explicit terms what actions they must perform
Languages that computers can understand need to be precise and exact
Every structure in a programming language has a precise form (syntax) and a precise meaning (semantics)
Programs are often referred to as computer code and the process of writing an algorithm in a programming language is called coding 13
![Page 14: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/14.jpg)
Programming
Programming languages are considered “higher level” languages
Computer hardware can only understand “low-level” languages referred to as “machine language”
Computers understand binary (1s and 0s)
A higher level language is converted into a lower level language by:CompilationInterpretation 14
![Page 15: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/15.jpg)
Compiler vs Interpreter
15
Compiler Interpreter
Takes high level source code and converts it into low level machine code
Analyzes and executes source code instruction by instruction
Once program is compiled, it can be run multiple times without needing the compiler and source code
Interpreter and source needed every time the program is run
Compiled programs are generally faster
Interpreted programs are more flexible as you can develop and run programs interactively
![Page 16: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/16.jpg)
Portability
Machine language is specific to a particular CPU
Each kind of computer has its own machine language
Programs written in a high level language can be run on different computers as long as a compiler and interpreter exists for that computer
16
![Page 17: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/17.jpg)
Python
It is an interpreted languageSimple yet powerful and robustGood initial language to learn
programmingCompanies that use Python
GoogleYahooDisneyIBMNASA 17
![Page 18: CS 127 Introduction to Computer Science. What is a computer? “A machine that stores and manipulates information under the control of a changeable program”](https://reader033.vdocuments.us/reader033/viewer/2022052702/56649f585503460f94c7d4fe/html5/thumbnails/18.jpg)
Running Python programs
IDLE GUICommand line InterpreterGood resource
http://www.python.org/doc/
18