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...

Write a program to print the prime numbers from 1 to 100?

Answer Posted / dash

#include<stdio.h>
#include<conio.h>

void main()
{
int number,i;
clrscr();

for(i=1;i<=100;i++)
{
if(i%2==0)
{
printf("\n\n not prime number\t%d",i);
}
else

printf("\n\n prime number\t%d",i);
}
getch();
}

Is This Answer Correct ?    31 Yes 86 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain how do you convert strings to numbers in c?

1067


How do you list files in a directory?

1126


if the area was hit by a virus and so the decrease in the population because of death was x/3 and the migration from other places increased a population by 2x then annually it had so many ppl. find our the population in the starting.

5215


What is formal argument?

1123


Can math operations be performed on a void pointer?

1034


What are the disadvantages of a shell structure?

1329


illustrate the use of address operator and dereferencing operator with the help of a program guys plzzz help for this question

2057


why return type of main is not necessary in linux

2091


main use of recursive function a) processing speed high b) reduce program length/reduce repeated statements c) if you do not, use iterative methods like, for, while or do-while d) all the above

1073


What is pragma c?

1097


In c programming write a program that will print 10 multiples of 3 except 15,18,21 using looping

1498


Why we use break in c?

989


What is far pointer in c?

1300


Do character constants represent numerical values?

1321


What is the use of a conditional inclusion statement in C?

1045