try this u can find out all prime number between 2 and any
number entered by user .i write code in c# language but
concept remain same in any language.
static void Main(string args)
int i=2, j, rem;
while (i <= 100)
for (j = 2; j < i; j++)
rem = i % j;
if (rem == 0)
if (i == j)
2. What is the function of ceil(X) defined in math.h do?
A)It returns the value rounded down to the next lower
B)it returns the value rounded up to the next higher integer
C)the Next Higher Value
D)the next lower value
9.how do you write a function that takes a variable number
of arguments? What is the prototype of printf () function?
10.How do you access command-line arguments?
11.what does ‘#include<stdio.h>’ mean?
12.what is the difference between #include<> and #include”…”?
13.what are # pragma staments?
14.what is the most appropriate way to write a