Skip to content
This repository has been archived by the owner on Jun 14, 2024. It is now read-only.

Create To use continue and break in C #158

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 26 additions & 0 deletions To use continue and break in C
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
#include<stdio.h>
#include<conio.h>
void main()
{
int n,i,a[20];
clrscr();
printf("\n ENTER THE VALUE OF N ");
scanf("%d",&n);
for(i=1;i<=n;i++)
{
printf("\n ENTER %d NUMBER: ");
scanf("%d",&a[i]);
if(a>0)
{
continue;
}
if(a>=100)
{
break;
}
sum=sum+a[i]
}
printf("\n SUM IS : %d ",sum);
getch();
}