How to include external file in to your C++ program:
1. Create an external file and save it with h extension in include directory.
The include directory can be found in your installation directory.
Example: your myTriangle.h file contains the printTriangle function as shown below:
2. To use the printTriangle function in your C++ program, you must include the myTriangle.h file in your program:
using namespace std;
Posted by: Dara | post date: 12-09-2012 | Subject: C++ Programming Language
This website intents to provide free and high quality tutorials, examples, exercises and solutions, questions and answers of programming and scripting languages: