Translate

Saturday, 15 February 2014

C++ Programming

This week we move on to C++ programming which was designed by Bjarne Stroustrup. Commonly referred to as C with classes, the language extends to object orientation. Simula is object oriented and contained many features that where borrowed to make C++. C++ application can be seen in many different operating systems and embedded system, this makes it one of the most popular programming language. C++ has even inspired the creation of other programming language like C#(sharp) and Java.

# include <iostream>

int main()
{
   std::cout << "Hello, world!\n";
}


So the above program is going to output:

Hello, world!

Of course being that C++ contains the same syntax as C the rules and constructs apply. However there are additions and differences to note.

Operators
The programming language contains operators which can be overloaded and have multiple uses.

Memory Management
C++ management of memory can be classified in several ways. The access you get from memory is clearly great.


Templates
C++ Templates allow the creation of generic programs that can define class and function that behave specifically at compile time.

Objects Oriented
C++ is an OOP(Object Oriented Programming Language) that supports encapsulation, inheritance, polymorphism and abstraction.

No comments:

Post a Comment