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
Explain how do you convert strings to numbers in c?
How do you list files in a directory?
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.
What is formal argument?
Can math operations be performed on a void pointer?
What are the disadvantages of a shell structure?
illustrate the use of address operator and dereferencing operator with the help of a program guys plzzz help for this question
why return type of main is not necessary in linux
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
What is pragma c?
In c programming write a program that will print 10 multiples of 3 except 15,18,21 using looping
Why we use break in c?
What is far pointer in c?
Do character constants represent numerical values?
What is the use of a conditional inclusion statement in C?