Acceptable Use of the goto Statement? So, I made a console interface. It prompts users with several options they can enter. 1 for the first option, 2 for the second option, etc. Using the switch statement, each option will bring them to a different screen. Now, after any of the options are entered and the users are brought to a particular screen, how do I get them back to the selection screen with those options? Would it be acceptable for me to do something along the lines of

selectionScreen:

printf("Enter 1 for the First Screen\n");
printf("Enter 2 for the Second Screen\n");
printf("Enter 3 for the Third Screen\n\n");

scanf("%d", &amp;selection);

switch (selection)
{

case 1:

    //do and print stuff here

    for (i = 0 ; ; i ++)
    {

        //do and print stuff here

        while(GetAsyncKeyState(VK_TAB))
        {

            goto selectionScreen;

        }

         printf("Enter the Tab key to go back the selection screen.\n\n");
         printf("Enter any key besides Tab to reload!\n\n");

         getchar();

         system("CLS");

     }

    break;

case 2:

    //do and print stuff here

    for (i = 0; ; i++)
    {

        //do and print stuff here

        while(GetAsyncKeyState(VK_TAB))
        {

            goto selectionScreen;

        }

         printf("Enter the Tab key to go back the selection screen.\n\n");
         printf("Enter any key besides Tab to reload!\n\n");

         getchar();

         system("CLS");

     }

    break;

case 3:

    //do and print stuff here

    for (i = 0 ; ; i++)
    {

        //do and print stuff here

        while(GetAsyncKeyState(VK_TAB))
        {

            goto selectionScreen;

        }

         printf("Enter the Tab key to go back the selection screen.\n\n");
         printf("Enter any key besides Tab to reload!\n\n");

         getchar();

         system("CLS");

     }

    break;

default:

    //do stuff here

}


Or is there a more favorable way of doing this
I'm unsure if the posted code is exactly what's intended functionally, but the following would do the equivalent:

do
{
    printf("Enter 1 for the First Screen\n");
    printf("Enter 2 for the Second Screen\n");
    printf("Enter 3 for the Third Screen\n\n");

    scanf("%d", &amp;selection);

    if ( selection &lt; 1 || selection &gt; 3 )
        break;

    switch (selection)
    {
    case 1:
        //do and print stuff here
        break;

    case 2:
        //do and print stuff here
        break;

    case 3:
        //do and print stuff here
        break;
    }
}
while ( GetAsyncKeyState(VK_TAB) );


I really can't remember the last time I used a goto. I think it was in a FORTRAN class.