What is the output of given program if user enter "xyz" ?
#include
					 Home | Discussion Forum
					 
						
                        
                    
                    

Free Online Test

Taiyari24Hour

What is the output of given program if user enter "xyz" ?

#include
void main()
{
float age, AgeInSeconds;
printf("Enter your age:");
scanf("%f", &age);
AgeInSeconds = 365 * 24 * 60 * 60 * age;
printf("You have lived for %f seconds", AgeInSeconds);
}



View More Related Question

1) What will be the output of the following C code?

 #include <stdio.h>
void main()
{
int x = 0;
if (x == 0)
printf("hi");
else
printf("how are u");
printf("hello");
}

2) What will be the output of the following C code?

 #include <stdio.h>
void main()
{
int x = 5;
if (x < 1)
printf("hello");
if (x == 5)
printf("hi");
else
printf("no");
}

3) What will be the output of the following C code?

 #include <stdio.h>
int main()
{
if (printf("%d", printf(")))
printf("We are Happy");
else if (printf("1"))
printf("We are Sad");
}

4) If the following loop is implemented:

 {
int num=0;
do
{
--num;
printf("%d", num);
num++;
}
while(num>=0);
}

5) How many times will the following loop be executed?

 ch ='b';
while(ch>='a' && ch<='z')
ch++;

UP Gk Online Test

taiyari24hour.com

Study 2 Online Says....
Kindly log in or signup.