I can't link to the other file called A1.c, A2.c and A3.c respectively. Does anyone knows how to link to the other .c file from the following .c file?
Code:
#include<stdio.h>
int main()
{
int choice;
printf(" Main Menu\n");
printf(" =========\n\n");
printf("1.Simple Editor with Speed Calculation\n");
printf("2.Simple Spell Checking\n");
printf("3.Find & Replace\n");
printf("4.Quit\n\n");
do
{
printf("Please enter your choice: ");
scanf("%d",&choice);
}
while(choice<1 || choice>4);
if(choice==1)
{
fopen("A1.c","r");
}
else if(choice==2)
{
fopen("A2.c","r");
}
else if(choice==3)
{
fopen("A3.c","r");
}
else if(choice==4)
{
printf("Welcome to come next time.");
exit(1);
}
system("PAUSE");
return 0;
}
Comment