Skip to main content

DIFFERENCE BETWEEN BREAK AND CONTINUE


/*program to see the use of continue statement*/
#include<stdio.h>
#include<conio.h>
void main()
{
int i,j;
  clrscr();
printf("DIFFERENCE BETWEEN BREAK AND CONTINUE\n");
printf("PRINTING IN CASE OF CONTINUE\n");
for(i=1;i<=3;i++)
 {
for( j=1;j<=3;j++)
 {
 if(i!=j)
  continue;
  printf("%d %d   ",i,j);
 }
 }
printf(" \n");
printf("PRINTING IN CASE OF BREAK \n");
for(i=1;i<=3;i++)
 {
for( j=1;j<=3;j++)
 {
 if(i!=j)
  break;
printf("%d %d",i,j);
 }
 }


  getch();
}
/* click the below picture to maximize it /*


SIMPLE PROGRAMS
FUNCTIONS


NUMBERS


STRINGS AND CHARACTERS

Comments

Popular posts from this blog

unix commands