juz open turbo c and type is following code
#include <stdio.h>
#include <conio.h>
void get()
{
printf("Hi this is from header\n");
}
void put()
{
printf("bye");
}
// once you write this file save it as myheader.h in ur turbo c editor
***************************************************************
Now you open a new file in turbo c and then start writing is code given below:
#include "myheader.h"
void main()
{
get();
put();
}
save this file as sample.c and see it works ///
#include <stdio.h>
#include <conio.h>
void get()
{
printf("Hi this is from header\n");
}
void put()
{
printf("bye");
}
// once you write this file save it as myheader.h in ur turbo c editor
***************************************************************
Now you open a new file in turbo c and then start writing is code given below:
#include "myheader.h"
void main()
{
get();
put();
}
save this file as sample.c and see it works ///
great work but this good too:
ReplyDeletehttp://kodingexamples.blogspot.com/2014/04/how-to-create-header-files-in-cc.html