1. Trang chủ
  2. » Giáo án - Bài giảng

Giáo trình C++ - Ngành CNTT - Part 01

61 457 0

Đang tải... (xem toàn văn)

Tài liệu hạn chế xem trước, để xem đầy đủ mời bạn chọn Tải xuống

THÔNG TIN TÀI LIỆU

Thông tin cơ bản

Định dạng
Số trang 61
Dung lượng 1,04 MB

Nội dung

[...]... 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 11 Display 1.2 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Back Next Slide 1- 12 Data or Code?    ‘A’ may look like 010 00 001 65 may look like 010 00 001 An instruction may look like 010 00 001  How does the computer know the meaning of 010 00 001?  Interpretation depends on the current instruction... Addison-Wesley Slide 1- 21 Low-level Languages  An assembly language command such as ADD X Y Z might mean add the values found at x and y in memory, and store the result in location z   Assembly language must be translated to machine language (zeros and ones) 011 0 1 001 1010 1011 The CPU can follow machine language Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 22... as Pearson Addison-Wesley Slide 1- 18 Computer Input  Computer input consists of  A program  Some data Display 1.3 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 19 Display 1.3 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Back Next Slide 1- 20 High-level Languages  Common programming languages include … C C++ Java COBOL Lisp... Compilers  Translate high-level language to machine language  Source code   The original program in a high level language Object code  The translated version in machine language Display 1.4 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 23 Display 1.4 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Back Next Slide 1- 24 Linkers  Some... code for the programs we write and  The object code for the pre-compiled routines into  The machine language program the CPU can run Display 1.5 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 25 Display 1.5 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Back Next Slide 1- 26 History Note  First programmable computer  Designed by... Pearson Addison-Wesley Algorithms  Algorithm  A sequence of precise instructions which leads to a solution  Program  An algorithm expressed in a language the computer can understand Display 1.6 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 30 Display 1.6 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Back Next Slide 1- 31 Program... only or re-writable Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 15 Memory Access  Random Access  Usually called RAM   Computer can directly access any memory location Sequential Access  Data is generally found by searching through other items first  More common in secondary memory Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley... Publishing as Pearson Addison-Wesley Slide 1- 27 Section 1.1 Conclusion  Can you…  List the five main components of a computer?  List the data for a program that adds two numbers?  Describe the work of a compiler?  Define source code? Define object code?  Describe the purpose of the operating system? Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 28 1.2 Programming... Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 13 Secondary Memory   Main memory stores instructions and data while a program is running Secondary memory  Stores instructions and data between sessions  A file stores data or instructions in secondary memory Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Slide 1- 14 Secondary Memory Media  A computer might... Results may require modification of the algorithm and program Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Display 1.7 Slide 1- 34 Display 1.7 Copyright © 2007 Pearson Education, Inc Publishing as Pearson Addison-Wesley Back Next Slide 1- 35 Object Oriented Programming  Abbreviated OOP  Used for many modern programs  Program is viewed as interacting objects  Each . Addison-Wesley Data or Code?  ‘A’ may look like 010 00 001  65 may look like 010 00 001  An instruction may look like 010 00 001  How does the computer know the meaning of 010 00 001?  Interpretation depends on. disk Slide 1- 9 Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Back Next Display 1.1 Slide 1- 10 Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Computer. data Slide 1- 12 Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Back Next Display 1.2 Slide 1- 13 Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Data

Ngày đăng: 14/07/2014, 11:00

TỪ KHÓA LIÊN QUAN

w