excess to .h file

I made a program and save it . In the folder I can get the .cpp file but not .h file .Can anyone please tell me where can I get the .h file of my program ?
You have to write it.
thank you jsmith for you lecture . I learnt alot from that.
Can you please tell me how to write it or give an example .
1
2
3
4
5
6
7
8
//includes, directives, etc.

#ifndef _YourHeader
#define _YourHeader

//declarations

#endif 
Last edited on
1
2
3
4
5
6
7
8
9
#ifndef _.h
#define _.h

void MilesperGal();
void mileage();
void fuelUsed ();

#endif 
]


Is this what you mean ?
Last edited on
Is is ok to save the program with extension .h ?
Save the main program as a .cpp and save the header as .h.
If it is just a small program then I wouldn't worry about conditional compilation.
Topic archived. No new replies allowed.