Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction to Computer Algorithmics and Programming Ceng 113 What is a Program?

Similar presentations


Presentation on theme: "Introduction to Computer Algorithmics and Programming Ceng 113 What is a Program?"— Presentation transcript:

1 Introduction to Computer Algorithmics and Programming Ceng 113 What is a Program?

2 What does a computer do? A computer process data. A program is a list of detailed instructions that computers carries out. Data? Information?

3 A bit of history

4 Who is the programmer? Design and write programs that direct the computer to take raw data and transform that data into meaningful information for the end-user.

5 Common Misconceptions Don’t fear computers. Computers are tools to help you get your job done! “Only math experts can program computers”. “Computer makes mistakes”. “Computers are difficult to use”.

6 Computer Information System A system is a collection of interrelated parts that work together for a common goal. Hardware Software People Data Procedures

7 Hardware

8

9

10 A Motherboard CPU Power Supply Disk Memory Expansion Slots

11 Desktop PC

12 Portable

13 Handheld

14 Midrange Servers –Minicomputer or midrange computer: medium-sized computer used to host programs and data for a small network –May consist of a collection of individual circuit boards called blades (blade servers)‏

15 Mainframe Computers –Standard choice for large organizations, hospitals, universities, large businesses, banks, government offices –Larger, more expensive, and more powerful than midrange servers; usually operate 24 hours a day –Also called high-end servers or enterprise-class servers

16 Super Computers –Fastest, most expensive, most powerful type of computer –Space exploration, missile guidance, satellites, weather forecast, oil exploration, scientific research, complex Web sites, decision support systems, 3D applications –Commonly built by connecting hundreds of smaller computers, supercomputing cluster

17 Computer Networks

18 Software Operating Systems Application programs Utility programs

19 Software Operating Systems Application programs Utility programs

20 Operating System Hardware Operating System Programming Languages Databases Spreadsheets Word Processors The operating system helps the software communicate with the hardware.

21 People

22 Data

23 Procedures

24 What is a Program? Why are the programs like directions to the computer? Why do programs have to be so detailed? Why must programs reside in memory instead of remaining on the disk drive when you execute them?

25 Programs as directions A program is a list of detailed instructions that the computer carries out. Example: How you would describe starting a car to someone from the past.

26 Programs as directions Example Example: How you would describe starting a car to someone from the past. Solution 1: Use this key. Start the car.

27 Programs as directions Example Example: How you would describe starting a car to someone from the past. Solution 2: Attached is the key to the car. You need it to start the car. With the key in hand, go to the car door that is closest to the front door of the house. Under the door’s handle, you will see a round silver-dollar-sized metal part in which you can insert the key. After sticking the key into the hole as far as it goes, turn it to the right until you hear a click. Turn the key back to the left until it faces the same way as it did when you inserted it and remove the key.

28 Programs as directions Example ( Continued.. )‏ Solution 2: 6. Open the door and get into the car. Be sure to sit infront of the round wheel. 7. Close the door. 8. On the right side of the column holding the big round wheel (called a steering wheel), you will see a slot in which you can put the key. He hasn’t even started the car yet!

29 Programs as directions Not only are the programming instructions themselves important, but so is their order!

30 Problem Solving 1.Identify the problem. 2.Understanding the problem. 3.Identifying alternative solutions. 4.Selecting the best solution. 5.Preparing a list of instructions to solve problem. 6.Evaluating solution

31 Examples Define; How can you –Make a cup of a cocoa? Write a solution to the problem of finding the largest number out of three numbers. –List the specific steps that would enable another person to find the largest among.

32 Programs are saved instructions. CPU...... RAM Disc Programs Process A program must be in memory before the CPU can execute the program’s instructions.

33 Programs are saved instructions. Instructions Of The Program CPU OUTPUTOUTPUT Screen Printer Disk Sound sys. The programs comes from disk, executes, and then sends its results to any of the many output devices. Data Program Operating System A typical memory layout.

34 Language The instructions you give in your programs must be in a language the computer understand. “10100110110011001101111101101011..” Computer and people are at opposite ends of the spectrum. Programming languages are a solution between people and computer, but they have a highly specific syntax.

35 The Language Translator Your program’s source code. Machine’s native language of 1s and 0s. Compiler Interpreter or Both interpreters and compilers translate source code into low-level machine language that the computer can understand.

36 Interpreters Foreign language book One line at a time. Interpreter You Translation An interpreter acts like a human interpreter. Therefore it can be slow process. BASIC uses an interpreter; example code is; FOR i = 1 TO 50 PRINT i NEXT i

37 Compilers Foreign language book Compiler You Translation Completely translated (compiled)‏ book. After compiling the book, you no longer need the translator.

38 Next Course Designing the program and so on..


Download ppt "Introduction to Computer Algorithmics and Programming Ceng 113 What is a Program?"

Similar presentations


Ads by Google