Presentation is loading. Please wait.

Presentation is loading. Please wait.

C/C++ Language Programming

Similar presentations


Presentation on theme: "C/C++ Language Programming"— Presentation transcript:

1 C/C++ Language Programming
Chapter 15 Course Review C/C++ Language Programming Wanxiang Che

2 Content 01 Basic Knowledge 02 Types and Operation
03 Selection Statements 04 Loops 05 Functions 06 Arrays 07 Pointers 08 Structures 09 Class and Object 10 Inheritance and Polymorphism 11 Files 12 GUI 13 Simple Data Structures 14 STL

3 01 Basic Knowledge What’s computer? Advantage of C/C++
Steps of C/C++ Developing C/C++ Programming Tools

4 02 Types and Operation How to read input from the keyboard
What is identifiers Various primitive data types Assignment statements and assignment expressions Constants How to convert numbers to a different type Programming style Distinguish syntax, runtime, and logic errors Debug logic errors

5 03 Selection Statements bool type Comparison and logical operators
Selection control if statements if ... else statements Nested if statements switch statements Conditional operator Know the rules governing operand evaluation order, operator precedence, and operator associativity

6 04 Loops while, do-while, and for loops Nested loops
Know the similarities and differences of three types of loops Implement program control with break and continue

7 05 Functions Create, invoke, and pass arguments to a function
The differences between pass-by-value and pass-by-reference Function overloading and default arguments The scope of local and global variables C++ mathematical functions Design and implement functions using stepwise refinement Recursive function and the benefits of using it How recursive function calls are handled in a call stack Solve problems using recursion Understand the relationship and difference between recursion and iteration

8 07 Pointers What is a pointer?
Declare a pointer and assign a value to it Access elements via pointers Pass arguments by reference with pointers The relationship between arrays and pointers Access array elements using pointers Use the new operator to allocate memory dynamically Test and convert characters using the character functions Store and access strings using arrays and pointers Process strings using the string functions

9 08 Structures Use structures to store different types
Nested structures Pointers to structures Structure arrays Pass structures arguments to function Abstract data types

10 09 Class and Object Understand objects and classes
Declare a class and create an object of a class Constructors Access object members using pointers Create objects using the new operator on the heap C++ string class Data field encapsulation this pointer Store and process objects in arrays friend functions and friend classes to composition relationships

11 10 Inheritance and Polymorphism
Derive class from a base class through inheritance Redefine functions in the derived class Distinguish differences between redefining and overloading Polymorphism and dynamic binding using virtual functions Abstract classes and pure virtual functions

12 11 Files ofstream and ifstream Test whether a file exists
Use an fstream object to read and write data Open a file with specified modes The difference between text I/O and binary I/O Write/read binary data using the write/read function Random file access

13 12 GUI What’s GUI? How to install and configure FLTK?
Add a Widget into a window How to draw graph? How to make animation?

14 13 Simple Data Structures
Create nodes to store elements in a linked list Access the nodes in a linked list via pointers Declare a LinkedList class for storing and processing data in a list Insert/remove an element into a list Implement the Stack/Queue class using a linked list

15 14 STL The relationships among containers, iterators, and algorithms
Distinguish sequence containers, associative containers, and container adapters Distinguish containers vector, deque, list, set, multiset, map, multimap, stack, queue, and priority_queue Access elements in a container using iterators Know and use various algorithms To use function objects in STL algorithms

16 C/C++语言的核心学习到此结束 本课程对语言核心的讲述并非面面俱到 学会原理,掌握思维 仅掌握语言的核心当然不能熟练运用语言
一些比较“偏”,很少用到的没有涉及 学会原理,掌握思维 复杂的表面都是简单的原理的外在表现 仅掌握语言的核心当然不能熟练运用语言 背下英语的所有单词和语法,你就能写出莎士比亚一样的诗句了吗? 想写出好的文章,除了掌握语言,还要多读多写,才能自如运用语言写出漂亮的文章。 “熟读唐诗三百首,不会吟诗也会诌” 编程也是如此。写出漂亮程序的本事不是上课学出来的,也不是看书看出来的,而是读别人的程序读出来的,更是自己动手练出来的。

17 Ending and Beginning

18 Examination Time Location 16th Week, Thurthday (2009-12-16)
15:45 ~ 17:45 Location B11: , , B21: B31:


Download ppt "C/C++ Language Programming"

Similar presentations


Ads by Google