Download powerpoint 1

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project

Document related concepts

C Sharp (programming language) wikipedia, lookup

Compiler wikipedia, lookup

History of compiler construction wikipedia, lookup

Parallel computing wikipedia, lookup

Transcript
What's a Computer?
Disk
Monitor
Central
Processing
Unit
Main
Memory
Keyboard
mouse
Network
CPU: (stupid) brain of the computer
can do very simple tasks VERY FAST
add, write in memory...
Goal: Perform elaborate tasks by putting
together many simple tasks
HOW ?
142 A-1
Write a program!
• To solve a specific problem: weather
forecast, payroll, word processing, traffic
lights...
But A computer only understands instructions
written as a series of 0’s and 1’s
Could write as such, TIME CONSUMING..
MACHINE LANGUAGE
BETTER High level language
close (but ) to plain English
Need a compiler to translate our program
into 0’s and 1’s
What MSVC does for us
142 A-2
Which language?
Examples of High level languages:
• FORTRAN, LISP… 50’s (scientific)
• COBOL… 60’s (business)
• BASIC, PASCAL, C… 70’s (multipurpose)
• C++…80’s (OOP)
• Java, Java++… 90’s (platform independent)
What we will use
WIDESPREAD
A NECESSARY STEP TOWARDS C++, Java...
BUT
You will learn programming
C is not the point
A useful skill valid
for any language
142 A-3
How to write a program
• Clearly specify the problem
• Analyze the problem
• Find an algorithm to solve the problem
Logical series of tasks
Example: Managing a traffic light
Check the time
How long has it been since the light
has changed?
No
Long enough?
Yes
Change the light
Write the program (use C). DOCUMENTATION
Test and Debug (correct mistakes)
Maintain and Update
142 A-4
A little bit of history
Computers have improved dramatically
If the same had happened to cars:
• a Cadillac would cost $0.50
• 0 to 60 mph in 3 milliseconds
• Go to the moon and back on a tank of gas
• Could put the Cadillac in your pocket
Still Advancing
Pentium has 7.5 millions of transistors
300 millions in 10 years
Moore’s Law:
every 18 months, double the number of
components on a chip... for the same price
Should level off (?) in 20 years
Atom is the limit
(insulators are a few atoms thick)
142 A-5
What to Expect?
Programming is FUN
*
* and sometimes frustrating
• Read the book
• Come to class
• Get a lot of practice on the computers
And...
DO NOT
FALL
BEHIND
Rewards: plenty
Open doors in
• Education: Engineering, Computer Science,
Physics, Bio technologies...
• Employment: e.g. from ADOBE
_ Education: None
_ Experience: 3 years C++
_ Salary: $96,000
142 A-6
What Car makers say if
cars were like computers
For no reason whatsoever your car
would crash twice a day.
The airbag system would say "Are you sure?"
before going off.
Every time they repainted the lines on the
road you would have to buy a new car.
Occasionally your car would die on the
freeway for no reason, and you would just
accept this, restart and drive on.
Occasionally for no reason whatsoever,
your car would lock you out and refuse to let
you in until you simultaneously lifted the
door handle, turned the key, and grabbed
hold of the radio antenna
142 A-7