usingMaths.com
From Theory to Practice - Math You Can Use.







<< PreviousNext >>

Getting Started With C++



Development IDE

On Windows, Visual Studio now has a free version.
Go ahead and get it, and install the C/C++ platform tools.



Using Visual Studio

To create a new project: On the Start Page of Visual Studio, click New Project.
Select Visual C++ under the Template header and Win32 Console Application (for our purpose) under the .Net Framework header.
Give the project a name. >> OK >> Next >> Finish.

To Create a new C++ class file: click Project, Add Class.
Select C++ Class, Add;
Give the class a name and click Finish.



Running C++ Codes

To make sure your code contains no errors and see its output before you get to building it, set a breakpoint at the return statement in the main class:

Click on the left area of the "return 0" line to highlight it;
click Debug at the top of the window, Toggle breakpoint; a red dot appears on the return 0 line.

Press F5, (click Yes) to see the project run to completion - assuming there are no errors.
A new shell is created that shows the result of your code.

Alternatively, click Debug >> Start Without Debugging (Ctrl F5) to see your output.


Note: In Windows, C/C++ codes can also be run in the NetBeans IDE using Cygwin or MinGW libraries.



Notice: Our colour coding follows that of Microsoft's Visual Studio.







Visual Studio Start Page
Visual Studio Start Page
New Project
New Project
Next Step
Next Step
Finish New Project
Finish New Project
New Class
New Class
Finish New Class
Finish New Class



<< PreviousNext >>