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

In a header file whether functions are declared or defined?

627


Why do we use null pointer?

601


What is assert and when would I use it?

573


What are compound statements?

622


What does it mean when the linker says that _end is undefined?

625






What does 1f stand for?

604


What are enums in c?

655


How can I recover the file name given an open stream or file descriptor?

588


What is the difference between fread and fwrite function?

634


Explain the use of keyword 'register' with respect to variables.

586


What does void main () mean?

729


Explain what is operator promotion?

630


What oops means?

576


code for find determinent of amatrix

1511


a value that does not change during program execution a) variabe b) argument c) parameter d) none

689