C/C++ Programming  (2016 Fall Advancd Class)

Goals

(1) Understand the fundamental conceptions of C/C++ language, including data type, control statements, functions, array, pointer, …;
(2) Understand the principles of process-based/object-oriented software design, including Functions, Points, Arrays/ Class, object, Inheritance, …;
(3) Have the basic ability and skill in C/C++ basic programming;
(4) Know about the background of software programming and software engineering.


Classroom and Laboratory

(1) Every Tuesday Evening and Friday Morning in Week 5,7-17:
(2) Programming Test: 2016-12-23
(3) Paper Test:to be annouced


Syllabus

Week

Category

Date

Lecture Content

Experiment

W5

Lecture1

9-27

Topic: Introduction [slide]

Instruction: Basic coding [slide][ANS]
Task: menu.
常见错误列表

W5

Lecture2

9-30 Topic: Basic programming with C [slide]
Instruction: Basic coding [slide][ANS]
常见错误列表

W7

Lecture3

10-11 Topic: Control statement 1 [slide] Instruction: Control statement [slide][ANS]

W7

Lecture4

10-14 Topic: Control statement 2 [slide]

Instruction: Control statement [slide][ANS]

W8

Experiment 10-18 Experiment 01-04 华中科技大学2016-2017年校历

W8

Lecture5

10-21 Topic: C function 1 [slide] Instruction: Function-part1 [slide][ANS]

W9

Lecture6

10-25 Topic: C function 2 [slide] Instruction: Function-part2 [slide][ANS]

W9

Lecture7

10-28 Topic: C array 1 [slide]

Instruction: Array-part1 [slide][ANS]

W10

Lecture8

11-1 Topic: C array 2 [slide]

Instruction: Array-part2 [slide][ANS]

W10

  11-4 Cancelled due to sports meeting  

W11

Experiment 11-8 Experiment 05-08
补充讲义-排序算法: 冒泡排序、插入排序、选择排序[slide]
 

W11

Lecture9

11-11 Topic: C pointer 1 [slide] Instruction: Pointer-part1 [slide][ANS]
W12

Lecture10

11-15 Topic: C pointer 2 [slide] Instruction: Pointer-part2 [slide][ANS]
W12

Lecture11

11-18 Topic: C struct [slide]
Instruction: Struct [slide][ANS]
W13

Lecture12

11-22
Topic: Linked list [slide]
课堂演示程序: 链表的创建、显示、插入和删除[code]

Instruction: Linked list-part1 [slide][ANS]

W13 Experiment 11-25 Programming Test  
W14

Lecture13

11-29

Topic: Difference between C and C++[slide]
补充讲义-C程序的内存管理 [slide]
课堂演示程序: 引用和指针的对比[code]
课堂演示程序: 函数默认参数、函数重载、函数模板[code]

Instruction: Linked list-part2 [slide][ANS]
补充讲义: 课程表程序的软件工程分析[slide]

W14

Lecture14

12-2

Topic: Introduction to object-oriented programming [slide]

Instruction: Basic class programming [slide][ANS]
W15

Lecture15

12-6 Topic: Advances in C++ Class[slide] Instruction: Advanced class programming [slide][ANS]
W15 Experiment 12-9 Experiment 13-15  
W16

Lecture16

12-13 Topic: Inheritance [slide] Instruction: Inheritance [slide][ANS]
W16

Lecture17

12-16 Topic: Polymorphism [slide] Instruction: Polymorphism [slide][ANS]
W17 Experiment 12-20 Experiment 16-17  
W17 12-23, Experiment report submission (Report template); Programming Test
  Paper Test


Reference Textbooks

[1] H.M.Deitel, P.J.Deitel, C How to program, 6th ,Pearson 2005
[2] H.M.Deitel, P.J.Deitel, C++ How to program  [digital version download], 6th ,Pearson 2005
[3] 谭浩强,《C++程序设计》,清华教育出版社,2004.6
[4] 郑莉 等,《C++ 语言程序设计》,清华大学出版社,2005.7
[5] 钱能 等,《C++ 程序设计教程》(第2版),清华大学出版社,2005.9

 

Reference on C++/C Coding guidelines and rules

[1] 林锐,顾晓刚,谢义军编著,《高质量程序设计指南—C++/C 语言》,电子工业出版社,2002-06
[2] 华为公司:编程规范(pdf),编程规范案例编程质量检查清单(互联网流传,未经证实)
[3] Google公司:编程规范 (互联网流传,未经证实)
[4] Andrew Koenig 著,高巍 译,《C陷阱与缺陷》,人民邮电出版社,2008-01
[5] 李健,《编写高质量代码:改善C++程序的150个建议》,机械工业出版社,2012-01
[6] Herb Sutter, Andrei Alexandrescu著,刘基诚 译,《C++编程规范:101条规则、准则与最佳实践》,2006-01
[7] 简明C语言编程规范(互联网流传)
[8] 刘威整理,本课程要求的C/C++语言编程规范

Resources

(1) Textbook[1] source code [download]
(2) Reference book for standard C/C++ functions [download]
(3) Development tool: Code Blocks [download] and in Chinese language patch [download]

Feedback

If you have questions, welcome write e-mail to liuwei@hust.edu.cn.
Due to the large number of spam e-mails, please add ``[C++][Question]'' as the prefix in the title of your e-mail.
That will help me to identify your e-mails, thank you.


<Last Updated: 2016 Fall>