Introduction: C++ Tutorials Part-1

Picture of C++ Tutorials Part-1

Hey guys! This is my first C++ tutorial.

In this tutorial we would cover -


Step 1: What Is C++

Picture of What Is C++

C++ is a mid-level programming language which was developed by Bjarne Stroustrup in 1979 in at&t bell laboratories.

This is a very simple to learn language if learnt with full interest in it. It is a very simple, yet powerful language.

This language can be used to create desktop applications, pc games, server applications, and many other performance-critical applications.

It is a mid-level OOP (object-oriented-programming) language and I will teach you about this.

Step 2: Materials Needed.

Picture of Materials Needed.

To make your first c++ programme you need the following-

●PROGRAMMING IDE - This is very much like a text editor, but a very modern and advance text editor. This ide is better than normal text editors like notepad as it has many features like - auto-completion, syntax highlighting (colouring of the code) etc. According to me I recommend you CODE BLOCKS ide.

●COMPILER - It is one of the main things required to build C++ programmes. A compiler basically converts the code in the form of text into the binary language which the computer can read and execute. The most popular and recomended compiler is GNU GCC compiler.

Step 3: Your First Hello World Programme.

Picture of Your First Hello World Programme.

To , make your first C++ programme

●STEP 1- Open your ide.

●STEP 2- Create a new project, a console application.

●STEP 3- Now write the above code in it.(in the image)

●STEP 3- Now save the code, build, compile and run it.

●STEP 5- When you will run the code a command prompt window will open and there would be the text 'hello world'. (you can later change the text)

Step 4: Understanding the Code

Picture of Understanding the Code

The meaning of the code -

■#include - This preprocessor directive tells the compiler to treat the contents of the code as if they appear in the source code at the point where the directive appears.

■ iostream - This library provides basic output and input functions.

■int main () - This line initiates a function, a funtion is a group of code statements which are given a name, in this case 'main'. I will tell about functions in the 'part 2'.

■cout<< - This is a basic C++ statement. It is functional and can produce some effect like output a piece of text. All statements end with a semicolon " ; ".

■return 0 ; - In this c++ programme the main funtion is of type 'int' and therefore we should return an integer value to it. This is considered the "exit status" of the application. IN SIMPLE LANGUAGE, IT TELLS THE OS THAT THE CODE RAN SUCCESSFULY WITH NO ERRORS.

Step 5: My Future Plans

Picture of My Future Plans

My next part-2 will be based on -



About This Instructable




Bio: I am 14 year old and a passionate technology enthusiast i want build my career as a software developer i love electronics,programming,android os ... More »
More by p mishra:BLOODY PAINTING HALLOWEEN PROP!!!Thin, instant matches that fit in your survival kit!!! omg!Light 40 Leds With a Dead Battery!!!
Add instructable to: