
-----------------------------------
Geminias
Tue Nov 08, 2005 7:09 pm

Hey Importing functions in C++?
-----------------------------------
i mine as well be asking this question specifically to wtd lol.  wtd, how do you import a function you've created already so you don't have to keep writing the same functions (or copy pasting them) into new source codes.  

for instance in turing there's a length function built in.  I'd like to make a file a cache for all the functions i find useful and thus be able to easily transport them around into new sources.  

am i thinking about this the wrong way?  is there something better than doing this?

-----------------------------------
wtd
Tue Nov 08, 2005 7:15 pm


-----------------------------------
First off... what are you trying to find the length of?  :)

Next, the mechanism you're looking for are header files.

There's a simple way to do this, and a correct way.

The simple way is to put everything in a header file that might look like:

#include 

void foo()
{
   std::cout 