Skip to content

Latest commit

 

History

History
25 lines (18 loc) · 908 Bytes

C++.md

File metadata and controls

25 lines (18 loc) · 908 Bytes
title description
C++
Some C++ update to C



 HOME 

New Dynamic Memory Allocation

There are just two keywords in C++

  • new: dynamic allocation. Syntax: ptr = new data-type(default value) for single allocation or ptr = new data-type[size] for array allocation
  • delete: dynamic de-allocation. Syntax: delete ptr for single allocation or delete[] ptr for array allocation

Template

STL

Standard Template Library

OOP

Object-Oriented Programming is the most important feature on C++ different from C

Some things outside

Have you ever wonder why C++ have everything C have and more but C is widely used in embedded ?
Because C++ and their library is much larger than C and embedded applications are usually have limited memory, not all hardware can satisfy