Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction COMP104: Fundamentals and Methodology.

Similar presentations


Presentation on theme: "Introduction COMP104: Fundamentals and Methodology."— Presentation transcript:

1 Introduction COMP104: Fundamentals and Methodology

2 COMP104 Lecture 1 / Slide 5 Objectives How to solve a problem (by computer) fundamental problem solving techniques How to design an algorithm algorithm design How to write a program in C++ implementation

3 COMP104 Lecture 1 / Slide 6 Course description l Introduction l C++ basics for Structured (or procedural) Programming l Sequential (assignments) l Branching (if statement) l Looping (while-do statement) l Arrays and algorithms l Functions (local/global, value/ref), recursion l Files l Pointers and dynamic objects l Linked lists l Introduction to OOP (Object Oriented Programming) l Classes, objects l Abstract data types mid-term static dynamic

4 COMP104 Lecture 1 / Slide 7 What can you do after this course? Program the computer in applications such as the following: Program a simple calculator Program simple computer games Program a simple text editor Program a small inventory system for a small company … You will be ready to take on part-time programming jobs during Xmas break!

5 COMP104 Lecture 1 / Slide 8 Course organization l Lectures (3 h) (office 3506, quan@cse.ust.hk) l Tutorials (1 h) l Not compulsary l Labs (2 h) l Compulsary! See lab policy. l Assignments (homework, 3 projects) Textbook: Programming in C++: Lessons and Applications, by Timothy B. D’Orazio No any prerequisite for comp104! But it’s a prerequisite for most of CS courses!

6 COMP104 Lecture 1 / Slide 9 A typical weekly schedule l Tu ThurLectures l Sat. Next lab posted on web l Mon-FriLab session (students encouraged to demo program by end of lab) l Sat. midnight Deadline for lab by CASS Course webpage: course.cse.ust.hk/comp104/Password_Only Print out ‘ppt’ with ‘handouts’ option!!! Newsgroup, Facebook? Eclipse tutorial SVG tutorial

7 COMP104 Lecture 1 / Slide 10 Grading l Labs (10%) l Assignments (25%) l Midterm exam (25%), 6 th week, l 9 th October, Sat. 1-3pm l Final exam (40%), Dec. Mark weighting

8 COMP104 Lecture 1 / Slide 11 Introduction to Computer Systems Hardware Software

9 COMP104 Lecture 1 / Slide 12 Hardware

10 COMP104 Lecture 1 / Slide 13 CPU - central processing unit Makes decisions, performs computations, and delegates input/output requests Memory: Stores information Main memory: RAM, e.g. 256 MB RAM Secondary memory: hard disk, e.g. 20GB Input devices Gets information from the user to the computer Output devices Sends information from computer to the user

11 COMP104 Lecture 1 / Slide 14 What is a program? A computer program performs a specific task, and may interact with the user and the computer hardware. Human work model: Computer work model: A program is a set of instructions

12 COMP104 Lecture 1 / Slide 15 What is a (programming) language? A program needs to be written in a language There are many programming languages Low-level, understandable by a computer High-level, needs a translator! C++ is a high level programming language A sequence of instructions A program (in computer language) An algorthm (in human language)

13 COMP104 Lecture 1 / Slide 16 Machine binary languageLow-level assemblyHigh-level An example:

14 COMP104 Lecture 1 / Slide 17 Machine binary language: unintelligible Low-level assembly language Mnemonic names for machine operations Explicit manipulation of memory addresses Machine-dependent High-level language Readable Machine-independent Levels of programming language

15 COMP104 Lecture 1 / Slide 18 How to translate? Examples of compilers: Microsoft Visual C++, Eclipse, g++ A program written in high-level programming language (for example, C++ program) A low-level (machine language) program that is understandable by a computer (for example, a PC) COMPILER (for example, Visual C++)

16 COMP104 Lecture 1 / Slide 19 Application software Programs designed to perform specific tasks and are easy to use System software Programs that support the execution and development of other programs Two major types Operating systems Translation systems (compilers & linkers) What is a software? The set of all programs or a set of programs

17 COMP104 Lecture 1 / Slide 20 Operating System (OS) Windows (DOS, NT, XP, …), Unix (Linux, Solaris, …) Common application software: Microsoft Word, WordPerfect PowerPoint Netscape, IE PhotoShop, Photo-Paint Quick Time

18 COMP104 Lecture 1 / Slide 21 We teach C++, Why? C++ is one of the most popular languages C++ (originally C) Basic, Pascal, Java, Perl, Cobol, Scheme, Lisp, Smalltalk, Ada, … C++ is portable (runs on PC, Machintosh, Unix, Mainframes …) C++ is widely used in industries (almost by everyone) C++ is not easy to learn  The most common versions of C++: Microsoft Visual C++ Eclipse g++ (for Unix machines) C C++

19 COMP104 Lecture 1 / Slide 22 Programming or Software Development Editing (to write the program) Compiling (creates.obj file) Linking with compiled files (creates.exe file) Object files Library modules Loading and executing Testing the program debug

20 COMP104 Lecture 1 / Slide 23 Integrated Development Environments (IDE) Editor Compiler Linker Loader Debugger Viewer Combine all of the capabilities that a programmer would want while developing software (VC++, Eclipse) builder

21 COMP104 Lecture 1 / Slide 24 Summary


Download ppt "Introduction COMP104: Fundamentals and Methodology."

Similar presentations


Ads by Google