Best C++ Programming Language Books For Beginners

The best way of starting to learn a programming language is by reading a book.

So if you are still a beginner in learning the C++ programming language, here's  a list of the best C++ books you can get started reading.

1. C++: The Ultimate Guide To Learn C Language

This C++ book by Peter Hoffman which is aimed for beginners. The book has 66 pages which is indeed a short book which a beginner can go through within one day. 

This book teaches the basic of the C++ language. Through this book, you will learn how to make your first program in less than 10 minutes. It also teaches about variables, operators, loops, conditions and pointers. This is a good starting point for a true beginner.

Best C++ Books for Beginners

2. Learn C++ In A Day

This book is a crash course for learning the basics of C++ programming language.

What this books is offering to beginners includes the uses of C++ language and the basics features of the language. The lessons will include on program structure, comments, functions, variables, data types, operators, advance data types, loops, conditional statements, arrays, pointers and object oriented concepts in C++ like inheritance.

This book has a total of 136 pages for its paperback version.

3. C++: The Ultimate Beginner's Guide

This book has 84 pages which offers almost the similar basic lessons about the C++ language. 

Through this book, you will learn the basic syntax of C++ language and its basic features. There are lessons about data types, variables, operators, loops, conditional statements and functions. 

This is a short book and it offers you a clear overview of what C++ language is and the opportunity of learning more. 

What's good in reading a short book is the feeling of fulfillment once you read the whole book. It's one good milestone towards learning.

This books are from Amazon and one good thing is that there are reviews of customer who already bought any of these books. You can check out their reviews and see if you can also benefit based on your current learning needs.

Hope that this will be helpful to you in your journey towards learning C++ programming language. 

Keep on reading C++ books because that will truly help you.

Learn C++ From Scratch Series

In every thing, a beginner would always want to know what he needs in order to start learning, where to start and how to start. In the same way, becoming a software developer or programmer, one has to start learning from the start. Knowing this need, this page will help a beginner of C++ to take every step learning how to program C++. This is a series of topics and tutorials which will help a beginner to take learning in a step by step process.

Listed are the topics and posts which are set in order so that a C++ student will know which to topic to learn and take first. This is a path to learning C++ through explanations and examples.

We will leave to you the research about the C++ programming language as there are plenty of resources in the web about C++ and software development in general. So in this tutorial, we will help you create your first program, run it up to learning how to program in C++ by yourself.

The most important thing is that to enjoy what you're doing.

What do you need to start coding your program? You will need to have a development environment and for this, we will use Microsoft's Visual Studio. There is the Microsoft Visual Studio Express version if you want a free, lightweight version which is intended for students and hobbyist like you. You can always buy for a premium version anytime if you want.

Happy coding!

For easy navigation of the lessons, I have placed them in the left side panel of this page - the BEGINNER's GUIDE will contains the topics to learn from top to bottom arrangement.

I will add lessons as I go. I'm still starting this page, so I hope you will bear with me. Your suggestions are welcome. Please subscribe if you want to be notified whenever, I post a new tutorial lesson or a new sample program.

I hope that this guide helps you as a learner of C++ language. Please feel free to contact me if you have any suggestions, clarifications and questions, see contact page.

Thank you very much! Enjoy and happy learning!

How To Create A C++ Win32 Application Project in Visual Studio

As a beginner, one has to start learning a programming language through reading a tutorial and to try out himself the examples as he goes through the tutorial. This way he can experience how a program runs and he can see what it looks like. Thus, it is extremely important that as a beginner, he should know where to write the programs. The application, where someone use to write a program, is called an editor. But for one to write and run his programs, programmers use the applications called an IDE (Intergrated Development Environment) which contains an editor, compiler and other sets of useful software development tools.

When someone begins to study a programming language, the most fulfilling achievement and inspiration is to be able to run a program himself. This will help add up to the excitement and yearning for learning the programming language and software development in general.

Let take the first steps of learning C++. There are plenty of IDEs but let's take Microsoft's Visual Studio here and learn how to create a Visual C++ Win32 Console Application and start writing the first programs as a C++ programmer.

First, you should be able to download and install a Microsoft Visual Studio Express Version that you can use, just go to google and search for it in Microsoft's site. After you have downloaded and installed MS Visual Studio, then you can now proceed.

Run your MS Visual Studio and then follow the steps below.

For our tutorials, let us create a Win32 Console application which when we run the program, we can see the output in the console window. Don't worry about this for now, we will see the output anyway in our programs.

These are the steps on how to create a Visual C++ Win32 Console Application project:

1. Open your Visual Studio.
2. In the Menu, click to FILE.
3. Click New Project.
4. In the New Project window, make sure the template is Visual C++.
5. Then click Win32 Console Application for the project.

6. Change the Name, Location, Solution and Solution Name as desired. But changing the Name and Solution Name would be okay.
7. Click OK
8. A new window opens, the Win32 Application Wizard.
9. Click the Application Settings.
10. Choose Console Application and check Empty Project.

Now, you have a new empty project solution.

Now let us proceed to the next lesson, creating our first program - the famous HELLO WORLD program.

Multiplication Table (10 x 10)

C++ program for Multiplication table (10 x 10)

Write a multiplication table ( 10 x 10)
The following program shows a 10 x 10 multiplication table.
It uses the escape sequence for horizontal tab (\t) to properly align the table.

Multiplication Table (10 * 10)
#include <iostream>

using namespace std;

int main(void)
 int x,y;
 char waitInput;

 for(x=1; x<=10; x++)
  for(y=1; y<=10; y++)
   //use horizontal tab (\t) to align properly
   cout << "\t" << (x*y);


 return 0;

Reverse The Number

C++ program to reverse the number

Write a C++ program which ask for a number and reverse its digits.
Ex. Number = 1234 , the answer will be 4321
In order to reverse the number, we have to get the every digit starting from the rightmost or the last digit. In the above example it is number 4, then next is 3, then 2 until 1.

Steps to extract each digit and construct the reversed value of the number:

1) Extract the last digit through the use of modulus operator (%) to get the remainder when the a number is divided by 10.
2) Add the extracted digit to a reversed number variable (ex. reversedNum) which will be constructed. The variable should be initialized to 0 and must be multiplied with 10 before the extracted digit is added.
3) After the last digit is extracted, divide the number with 10 to eliminate the extracted digit and start again to Step 1. The cycle continues until there is number is already 0.

The following program shows how to reverse the digits of a number.

Reverse the number
#include <iostream>

using namespace std;

int main(void)
 long number, remainder, reverseNumber = 0;
 char hang;

 cout<< "Enter the number: ";
  //extract the last digit from the number
  remainder = number % 10;  

  //build the reverseNumber digit by digit
  reverseNumber = (reverseNumber * 10) + remainder;

  //exclude the last digit from the number
  //ready for the next evaluation
  number = number / 10;    

 cout<< "Reversed number = " << reverseNumber <<endl;
 //to let console stay
 return 0;
Output of the program:

//Sample 1

Enter the number: 1235
Reversed number = 5321

//Sample 2

Enter the number: 1023
Reversed number = 3201

//Sample 3

Enter the number: 5007
Reversed number = 7005

//*Sample 4

Enter the number: 012
Reversed number = 21

//*Sample 5

Enter the number: 210
Reversed number = 12

*Note that for inputs having 0 in the beginning and in the end, 0 will not be include in the output, See below:
Input = 012        Output = 21 ( 012 is considered as 12 because the 0 is not significant)
Input = 210        Output = 12 ( instead of 012, 0 is not significant in the answer)

Check If A Number Is A Prime Number

C++ program to check if a number is a prime number

Write a C++ program which checks if a number is a prime number or not?
A prime number is any natural number greater than 1 with no other positive factors other than 1 and itself. 

Let's take 5 as an example:
1 and 5 (the number itself) can evenly divide 5 so they are factors of 5.
2, 3, 4 are cannot evenly divide 5 so they are not factors of 5.
Therefore, 5 is a Prime Number.
The program below shows a number is asked and it is evaluated if a prime number or not.

Prime Numbers Between 1-1000

C++ program to find prime numbers between 1 to 1000

Write a C++ program which prints all the prime numbers from 1-1000. 

Prime numbers are numbers greater than 1 and which has 1 and the number itself as positive factors or divisors. It doesn't have a positive factor or divisors other than 1 and the number itself.

Let's take 5 for example:
1 and 5 (the number itself) can evenly divide 5 so they are factors of 5.
2, 3, 4 are cannot evenly divide 5 so they are not factors of 5.
Therefore, 5 is a Prime Number.

This is a program which shows the Prime Numbers from 1-1000.