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

Heyyy All,

Just a challenge .
A C program with if Else


if(){
/// insert sumthing
print ("in if")
// insert sumting
}

else {
///// insert sumthing
print ("in else");
//// insert sumthing
}

can anyone modify it so that program prints.
if and else both

Answer Posted / naveen

Program:

void main()
{
int check =1;
if(check==1)
{
printf(" If Block\n");
goto condition1;
}
else
{
condition1:
printf("Else Block");
}
}

Output:

If Block
Else Block

Is This Answer Correct ?    3 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a spanning Tree?

1506


What is the difference between constant pointer and constant variable?

1169


Which is not valid in C a) class aClass{public:int x;}; b) /* A comment */ c) char x=12;

1031


Give the rules for variable declaration?

1118


How pointer is different from array?

1020


How do I copy files?

1005


What does sizeof int return?

1027


How can I check whether a file exists? I want to warn the user if a requested input file is missing.

1087


Can 'this' pointer by used in the constructor?

1047


What does a function declared as pascal do differently?

1048


What is a file descriptor in c?

1058


Describe static function with its usage?

1156


What is the equivalent code of the following statement in WHILE LOOP format?

1252


What are global variables?

1121


Write a program to swap two numbers without using third variable in c?

1077