C++ Basic

Course Outline Outline
Reading Material
PowerPoint Slides intro.pptx
DayLabSharing
1 1
  • The project templates
  • The editor
  • The compiler
  • The main() function
  • Different type of programming errors
  • Using debugger
  • How to get help
  • Running the program
  • Ex01-01:GCD solution
  • Ex01-02: How to use debugger (No Code)
  • Ex01-03: Using help from the IDE (No Code)
2
  • Identifier and the rules in naming
  • Single line and block comments
  • Command line arguments
  • The return value from main() function
  • Functions as building block
  • Naming Convention
  • Sequential Statements
  • Simple I/O with cin and cout classes
  • Preprocessing
  • const Vs. macro constants
3
  • Conditions, Composite conditions, and Boolean logic
  • Zero is false, none zero is true
  • “Short circuit” in composite conditions
  • Branching Statement
4
  • do-while statement
  • while–do statement
  • for statement
  • goto statement
  • break statement in iteration
  • continue statement in iteration
  • Busy loop
  • The principal of “One in one out”
2 5
  • Data Types Concept
  • Simple/native data types
  • The sizeof keyword
  • Variables
  • Type casting
  • Bit Fields
  • Union
  • New types in C++
6
  • Data segment, Stack, and Heap
  • auto, static, extern and register keywords
  • Constraint on the register variables
  • Register parameters
  • Variable/Object Life Cycle
3 7
  • Operators and operands
  • The expression
  • Operators
  • Operator Types
  • Pitfall of the / operator
  • The new rules of assignment operator in C++
8
  • Compiler directives
  • Compiler Constants
4 9
  • Pointers is simple/native type
  • The value Vs address of the storage
  • Parameter passing by value for pointer
  • The power of indirect access
  • Addressing Arithmetic
  • Pointer casting
  • void pointer
  • Pointer of pointers
  • Pointer to functions
10
  • char as integer type
  • Coding scheme
  • Code Vs value
  • Control characters
  • Characters and String
  • String terminator
  • Escape characters in string
  • String manipulation
  • String and pointer
  • Standard string manipulation functions
11
  • Homogeneous Complex Data Type:Array
  • Array indexing and out of bound issue
  • Open declaration
  • Optional last comma
  • The use of sizeof keyword on array
  • Multidimensional Array
  • Array and pointers
  • Heterogeneous Complex Types: struct (Record)
  • Accessing items in a record
  • Pointer to record
  • The.and -> operator
  • Record of record
  • Array of Record
5 12
  • Non deterministic during compile time:
  • Dynamic Allocation
  • The Heap’s story
  • new operator Vs malloc function
  • delete operator Vs free function
  • The different between delete and delete[]
  • Dynamic allocation and pointers
  • Issues with dynamic allocation
13
  • Function prototyping
  • Multiple modules project
  • static functions
  • Header files
  • Parameter passing by value
  • Passing address as value using pointer parameter
  • The Synonym and Parameter passing by reference
  • Function Overloading
  • Default parameter value
  • Function return types
  • Recursive function call
  • auto variables and static variables
  • Stack overflow
14
  • .NET Managed Environment
  • What is C++ extension under Common Language Infrastracture
  • Basic understanding of GC
  • How GC solved C++ mamory leaking and fragmentation issues
  • What are the new challenges triggered by GC?
  • Start up C++ project for .NET programming
  • Managed classes and CLI types
  • gcnew instantiation & Handles
  • Tracking Reference
  • Boxing/Unboxing
  • Property and How to imlement it in C++ CLI
  • Delegate
  • CLI Arrays


Recommanded Books
TitleC How to Program. With an Introduction to C++
ISBN129211097X
AuthorPaul Deitel, Harvey Deitel
Year2016
Publisher Laxmi Publications
TitleLearn C++ by Example: Covers Versions 11 to 23
ISBN978-1-633-43833-0
AuthorBuontempo, Frances
Year2024
Publisher Manning Publications Co.
TitleC++ Programming Fundamentals
ISBN978-1-683-92976-5
AuthorDheeraj Malhotra, Neha Malhotra
Year2023
Publisher Mercury Learning and Information
TitleIntroduction to C++: 500+ Difficulty-Scaled Solved Programming Exercises
ISBN978-1-032-13606-6
AuthorGeorge S. Tselikis
Year2023
Publisher CRC Press
TitleC++ Programming Fundamentals
ISBN978-1-683-92976-5
AuthorDheeraj Malhotra, Neha Malhotra
Year2023
Publisher Mercury Learning and Information
TitleAn Introduction to Programming with C++
ISBN978-1-285-86011-4
AuthorDiane Zak
Year2016
Publisher Cengage Learning
TitleBeginning C++ Programming
ISBN978-1-787-12494-3
AuthorRichard Grimes
Year2018
Publisher Packt Publishing
TitleC++ CLI Primer For .NET Development
ISBN978-1-484-22366-6
AuthorVivek Ragunathan
Year2017
Publisher Apress
TitleIntroduction to Programming with C++
ISBN978-0-273-79324-3
AuthorDaniel Y Liang et al.
Year2014
Publisher Pearson
TitleMicrosoft Visual C++/CLI Step by Step
ISBN978-0-735-67517-9
AuthorJulian Templeman
Year2013
Publisher Microsoft
TitleSafe C++: How to avoid common mistakes
ISBN978-1-449-32093-5
AuthorVladimir Kushnir
Year2012
Publisher O'Reilly Media
TitleThe C++ Programming Language, 4th Edition
ISBN0-321-56384-0
AuthorBjarne Stroustrup
Year2013
Publisher Addison-Wesley Professional