Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how i m write c program 1.check prime number 2.prime number
series

Answer Posted / sulthan

#include<stdio.h>
void main()
{
int a,i,n=0;
printf("\nEnter the Number");
scanf("%d",&a);
for(i=1;i<=a;i++)
if(a%i==0)
n++;
if(n=2)
printf("Prime")
else
printf("NOT Prime");
}

Is This Answer Correct ?    5 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Hi can anyone tell what is a start up code?

2029


Why is c so popular?

1126


What is an operator?

1034


what does static variable mean?

1070


What is pointer to pointer in c language?

1077


How do you determine whether to use a stream function or a low-level function?

1099


Is there anything like an ifdef for typedefs?

1111


What is the meaning of c in c language?

1105


Differentiate abs() function from fabs() function.

974


Why is void main used?

1045


Define Spanning-Tree Protocol (STP)

1086


Is c is a middle level language?

1028


Describe wild pointers in c?

1074


What are variables and it what way is it different from constants?

1205


How can I invoke another program or command and trap its output?

1065