C and C++ core tutorial

A C++ tutorial including C,C++11 and C++14 programming tutorial with a new light on the advanced features of object-oriented programming which includes class,object,data hiding,data encapsulation, data abstraction,inheritance and polymorphism.The other features of C++ standard like templates,namespace, STL-Containers,exception handling and algorithms will be also discussed in detail.The source code of the program from the tutorial will be made available to you so,you can download it using the download button.

***Note:C++11 and C++14 is same as C++ except in C++11, and C++14 some features(libraries) are added to overcome the limitations faced by C++.So I will add the discussion of these new topics (libraries) when there relevant topics are discussed in the chapters.

In C++ software and how? I have introduced to some of the workings of well known software programmed in C++.The discussion will be based on the algorithm use and how to program them with C++.Although,the algorithm of some software are unknown there are many other algorithm that does the job and we will see how we can approach in making these software using different algorithm.So,better is your algorithm better will be your software .I believe the discussion will prove useful if you are planning to develop a software of your own.So,you better check it out.If I miss anything out it’s up to you to explore beyond,or you can contact me if you need any help.





Introduction to C++

 

A language developed by Bjarne Stroutoup and widely believed as one of the most difficult languages to learn .Well! I am not trying to scare you here. The fact is C++ originates from C.With the addition of object-oriented features in C ,C++ was born making it hard to code.Here’s a quote from the creator himself.

“C makes it easy to shoot yourself in the foot; C++ makes it harder, but when you do it blows your whole leg off.”

C++ actually means C+1 ,C is incremented(increased) by 1 to give C++.This shows the advancement in the language over C although a bit slower than C.

***Note:In some chapters I may even discussed some C codes to show how some program can be optimized with C codes.But,if you are not a fan of C or does not know C then neglect it.

The Index below shows the layout of the chapters and the topics included in the chapter.Every chapter will consist of two parts:Basics and Advanced.Under the Basic section we will discuss the topics only related to the chapter.Under the Advanced section the topics discussed is also related to the chapter but sometimes topics from other chapter may involve due to their relativity with the current topic.This is done to provide you the best possible way of learning the concept which may affect the understanding of some other topic.The material provided in this site may be used as a C++ beginner tutorial tool or as a reference.So you can either jump onto any chapter which interest you or start from Chapter 1 and proceed to the end.Choose whichever method seem best for you.Lastly use the comment section to comment or ask a doubt or whatever deem fit necessary.Enjoy and have fun with C++.

 
Index



001.Chapter 1 – Data Types


010.Chapter 2 – C of C++


1010.Chapter 10 – Dynamic memory allocation


1100.Chapter 12 – STL containers and iterator

 



C++11 and C++14 features

 
*C++11 using auto keyword.

*C++14 auto:new features

*C++11 using decltype() keyword.

*C++14 using decltype(auto) uses.

*C++11 constexpr :: it’s differences with const.

*C++11 enum : scoped enumeration

*C++11 range-based for loop

Smart Pointers
 
*C++11 Smart pointer : Shared pointer ; why is it call shared pointers?

*C++11 Member functions of shared_ptr class: use_count()unique()get()swap( )reset( ).

*C++11 shared_ptr class internal workings with code example

*C++11 Unique_ptr: what makes it unique?

*C++11 3 points why shared_ptr and unqiue_ptr constructor is made explicit?

*C++11 weak_ptr :a weaker shared_ptr

*C++11 auto_ptr : 4 points why it should not be used ?

*C++11 bad_weak_ptr :a class thrown as exception by shared_ptr.

*C++11 enable_shared_from_this : uses.

Allocators

*C++11 allocator : what is?

*C++11 allocator_traits: uses

 


Miscellaneous

 

*IDE | Compiler | GUI | Source code.

*The first program.

*Library and how it differs from header’s file.

*Standard C++ library.

*Static and Dynamic library.

*Creating Static and Dynamic library with Code::blocks.

*Compile-time and run-time, stack and heap , static and dynamic.

*How to obtain assembly language code of C++ in Code::blocks/Mingw.

*Suggested website and book for C++.

*Contact me.

The topics given in this C++ tutorial website including the C++11 and C++14 programming tutorials is a result of thorough research and study of the language,I hope it will prove useful to you in many ways.New posts will be updated constantly so do check it out frequently.Happy programming!