adplus-dvertising
frame-decoration

Question

Guess the output of the following program :
#include<stdio.h>
int main()
{
    int x = 10;
    float y = 10.0;
    if(x == y)
        printf("x and y are equal");
    else
        printf("x and y are not equal");
    return 0;
}

a.

x and y are equal

b.

Compile Error

c.

Run Time Error

d.

x and y are not equal

Posted under C Programming

Answer: (a).x and y are equal

Engage with the Community - Add Your Comment

Confused About the Answer? Ask for Details Here.

Know the Explanation? Add it Here.

Q. Guess the output of the following program :