Repeat my program from main function- C

Hi,i am new to c programming.. below show that my final project of my coding..coding is fine,but i want repeat my program from main function after first time attempt is finish without any error..i know that want to add looping to repeat program...but i don't know the concept..please help me to solve this problem..thanks..please..


/*Coding of Our Project*/
#include<stdio.h>
#include<conio.h>
main()
{

int languages,teater,movie,showtime;
int seats,seats2,jumlah,total2;
float total;



do
{
printf("\n>Choose Languages/Pilih Bahasa<\n");

printf("\n1.Malay languages/Bahasa Melayu");
printf("\n2.English languages/Bahasa Inggeris\n");
scanf("%d",&languages);
}
while(languages==0 || languages>=3);


if (languages==1)
{
printf("\nAnda telah memilih Bahasa Melayu");
printf("\nOleh itu,Sila tekan mana-mana kekunci untuk teruskan..");
getch();
}
else
{
printf("\nYou have choosen English languages");
printf("\nSo,Press any key to continue..");
getch();
}

do
{

if(languages==1)
{

printf("\n\n>Pilih Teater<\n");
}
else
{

printf("\n\n>Choose Theater<\n");
}
printf("\n1.GSC(Golden Screen Cinemas)");
printf("\n2.MBO(Malaysian Box Office)");
printf("\n3.Lotus Five Star\n");

scanf("\n%d",&teater);
}
while(teater==0 || teater>=4);

if(languages==1)
switch(teater)
{
case (1):
printf("\nAnda telah memilih GSC(Golden Screen Cinemas)\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;
case (2):
printf("\nAnda telah memilih MBO(Malaysian Box Office)\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;
case (3):
printf("\nAnda telah memilih Lotus Five Star\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;

}

else
switch(teater)
{
case (1):
printf("\nYou have choosen GSC(Golden Screen Cinemas)\n");
printf("Press any key to continue..");
getch();
break;
case (2):
printf("\nYou have choosen MBO(Malaysian Box Office)\n");
printf("Press any key to continue..");
getch();
break;
case (3):
printf("\nYou have choosen Lotus Five Star\n");
printf("Press any key to continue..");
getch();
break;


}

do
{

if (languages==1)
{

printf("\n\n>Pilih Filem<\n");
}
else
{

printf("\n\n>Choose Movie<\n");
}
printf("\n1.Robocop");
printf("\n2.Endless Love");
printf("\n3.I,Frankstein\n");
scanf("\n%d",&movie);
}
while(movie==0 || movie>=4);

if(languages==1)
switch(movie)
{
case (1): printf("\nAnda telah memilih filem Robocop\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;
case (2): printf("\nAnda telah memilih filem Endless Love\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;
case (3): printf("\nAnda telah memilih filem I,Frankstein\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;

}

else
switch (movie)
{
case (1): printf("\nYou have choosen Robocop\n");
printf("Press any key to continue..");
getch();
break;
case (2): printf("\nYou have choosen Endless Love\n");
printf("Press any key to continue..");
getch();
break;
case (3): printf("\nYou have choosen I,Frankstein\n");
printf("Press any key to continue..");
getch();
break;

}

do
{

if (languages==1)
{


printf("\n\n>Pilih Tayangan Masa<\n");
}
else
{


printf("\n\n>Choose Showtime<\n");
}
printf("\n1. 12.00 PM");
printf("\n2. 6.00 PM");
printf("\n3. 10.00 PM\n");
scanf("%d",&showtime);
}
while(showtime==0 || showtime>=4);

if (languages==1)
switch(showtime)
{
case(1): printf("\nAnda telah memilih tayangan masa anda pada pukul 12.00 PM\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;
case(2): printf("\nAnda telah memilih tayangan masa anda pada pukul 6.00 PM\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;
case(3): printf("\nAnda telah memilih tayangan masa anda pada pukul 10.00 PM\n");
printf("Sila tekan mana-mana kekunci untuk teruskan..");
getch();
break;


}

else
switch(showtime)
{
case(1): printf("\nYou have choosen 12.00 PM as your movie showtime\n");
printf("Press any key to continue..");
getch();
break;
case(2): printf("\nYou have choosen 6.00 PM as your movie showtime\n");
printf("Press any key to continue..");
getch();
break;
case(3): printf("\nYou have choosen 10.00 PM as your movie showtime\n");
printf("Press any key to continue..");
getch();
break;


}

if(languages==1)
{
printf("\n\n>Bilangan tempat duduk<\n");
printf("Dewasa : ");
scanf("%d",&seats);
printf("Kanak-kanak : ");
scanf("%d",&seats2);
jumlah=seats+seats2;
printf("Oleh itu,jumlah bilangan tempat duduk : %d Orang",jumlah);
printf("\nSila tekan mana-mana kekunci untuk teruskan..");
getch();
}

else
{
printf("\n\n>Number of booking seats<\n");
printf("Adult : ");
scanf("%d",&seats);
printf("Child : ");
scanf("%d",&seats2);
total2=seats+seats2;
printf("So,total number of booking seats : %d Person",total2);
printf("\nPress any key to continue..");
getch();
}



if (languages==1)
{

printf("\n\n>Harga<\n");
printf("\nDewasa = RM10.00");
printf("\nKanak-kanak = RM6.00");
printf("\nCukai Kerajaan = RM0.50");
total=(seats*10.00)+(seats2*6.00)+0.50;
printf("\nOleh itu,harga jumlah yang perlu dibayar ialah RM %.2f",total);
printf("\nSila tekan mana-mana kekunci untuk teruskan untuk melihat resit anda");
getch();
}
else
{
printf("\n\n>Payment<\n");
printf("\nAdult = RM10.00");
printf("\nChild = RM6.00");
printf("\nGoverment Tax = RM0.50");
total=(seats*10.00)+(seats2*6.00)+0.50;
printf("\nSo,the total amount that you have to pay is RM %.2f",total);
printf("\nPress any key to continue to booking for another");
getch();

}



getch();
return 0;

}
Post code in the code tags so that it is properly formatted and easier for forum members to read.

You can read about loops here http://www.cplusplus.com/doc/tutorial/control/

Read the loops section, also read http://www.cplusplus.com/doc/tutorial/functions/
Topic archived. No new replies allowed.