Lecture 1 - Page 18 : 29
Notes about C++
From C to C++
* Course Introduction
Overview of Advanced Programming - Part One
Overview of Advanced Programming - Part Two
Recommended use of your time
Course Approach - Part 1
Course Exam
Which compiler or IDE?
* A quick tour of C
Basic Observations
The Evolution of C
The Popularity of C and C++
The C preprocessor
Fundamental types
Arrays and Pointers
Arrays and Pointers: Examples
Structures and Unions
Structures: Examples
Function types
User defined types
Expressions and operators
Control structures
Functions and parameters
Call-by-reference parameters via pointers
C Program organization
Memory Allocation
The standard library
* C/C++ Compatibility
C/C++ Compatibility
C/C++ Compatibility - some small details
Function types
Functions in C can be used as data of function type
Only two possible operations on a function
Calling the function
Take the address of the function
Functions as types and data
Dealt with by means of function pointers
Use of the
dereference operator
and the
address operator
is often implicit
Functions are first class data in C, but they are not closures
The declaration syntax is obscure - difficult to read
C program with function pointer.
Same program - without explicit use of the address and dereferencing operators.
Same program - using a typedef to capture the function type.
An array of functions