COSC1557: Introduction to Computing. Haibin Zhu, PhD. AssistProfessor Department of Computer Science Nipissing University (C) 2002. Instructor. Haibin Zhu, Ph. D. Assistant Professor, Department of CS and Math, Nipissing University Room: A124A Ext.: 4434 Email: [email protected]
Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.
Haibin Zhu, PhD.
Department of Computer Science
Artificial Intelligence and Robotics
Database and Information Retrieval
Numerical and Symbolic Computation
Software Methodology and Engineering
Social and Professional ContextAreas of Computer Science
ARPANET – The beginning of the Internet
Novell announces NetwareTCP/IP
MOSAIC, Apple Newton
Hardware and Software
Computers have two kinds of components:
Central Processing Unit (CPU):
Random Access Memory (RAM)
Secondary Memory (Disk):
While accessing RAM is faster than accessing secondary memory, it is still quite slow, relative to the rate at which the CPU runs.
To circumvent this problem, most systems add a fast cache memory to the CPU, to store recently used instructions and data.
(Assumption: Since such instructions/data were needed recently, they will be needed again in the near future.)
The OS acts as the “manager” of the system, making sure that each hardware device interacts smoothly with the others.
It also provides the interface by which the user interacts with the computer, and awaits user input if no application is running.
Examples: Windows 2000, Windows XP, Windows-NT, UNIX, Linux, Solaris, MacOS, ...
Applications are non-OS programs that perform some useful task, including word processors, spreadsheets, databases, web browsers, C++ compilers, ...
Example C++ compilers/environments:
Programs that are neither OS programs nor applications are called user programs.
User programs are what you’ll be writing in this course.
As the program runs, it repeatedly fetches the next instruction (from memory/cache), executes it, and stores any results back to memory.
That’s all a computer does: fetch-execute-store, millions of times each second!
A sequence of statements that instruct a computer in how to solve a problem is called a program.
The act of designing, writing and maintaining a program is called programming.
People who write programs are called programmers.
A computer only understands machine language statements.
A machine language statement is a sequence of ones and zeros that cause the computer to perform a particular action, such as add, subtract, multiply, ...
ML statements are stored in a computer’s memory, which is a sequence of switches.
For convenience of representation, an “on” switch is represented by 1, and an “off” switch is represented by 0.
ML thus appears to be binary (base-2):
... required a programmer to write in ML...
Programming was very difficult!
Allowed a programmer to use mnemonics, which were more natural than binary.
Devise a set of statements that are close to human language (if, while, do, ...), plus a program to translate them into ML.
The set of statements is called a high level language (HLL) and the program is called a compiler.
High level languages (like C++) are
A program should solve a problem:
A computer has two kinds of components:
There are “levels” to computer languages: