Thursday, 20 March 2014

PROGRAM IN C TO PRINT THE NUMBERS FROM 1 TO 10 USING GOTO…

/*… HEY GUY’S  this is a simple program hope you like it..*/
#include <stdio.h>
void main()

int count = 1;
start:                                                                   /* label */
if ( count > 10 )
goto end;
printf( “%d “, count );
++count;
goto start;
end:                                                                     /* label */
putchar( ‘\n’ );
getch();
}

the output is:::::::::::::::::::

Image

No comments:

Post a Comment