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 can write all 1to 100 prime numbers using for loop,if and
break ?

Answer Posted / sandeep

#include<stdio.h>
main()
{
int a=2;

work:
printf("%d",a);
a=a+2;
check:
if(a<=100)
goto work;

}

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Program to find the sum of digits of a given number until the sum becomes a single digit. (e.g. 12345=>1+2+3+4+5=15=>1+5=6)

1099


What is the size of enum in c?

1059


which of the following statement is wrong a) mes=123.56; b) con='T'*'A'; c) this='T'*20; d) 3+a=b;

3159


#include { printf("Hello"); } how compile time affects when we add additional header file .

1852


What are the two forms of #include directive?

1100


Explain how can I prevent another program from modifying part of a file that I am modifying?

1037


A character flag or control mechanism that delineates one data item from another a) variable b) constant c) delimiter d) call by reference

1044


what value is returned to operating system after program execution?

2062


How is pointer initialized in c?

976


What is extern storage class in c?

943


Write a program to print ASCII code for a given digit.

1036


What is the difference between ++a and a++?

1153


all c language question

2377


What is the description for syntax errors?

1096


What is const volatile variable in c?

982