ExamVeda
Login
Home
Functions and Procedures in C plus plus
?

What will be the output of the following C++ code?
#include <iostream>
using namespace std;
namespace first
{
    int x = 5;
    int y = 10;
}
namespace second
{
    double x = 3.1416;
    double y = 2.7183;
}
int main ()
{
    using first::x;
    using second::y;
    bool a, b;
    a = x > y;
    b = first::y < second::x;
    cout << a << b;
    return 0;
}

Answer & Solution
Correct Answer: Option D
Let's discuss the solution. Join the discussion
Examveda
Question posted by Examveda
Community

Join the Discussion

No comments yet Be the first to discuss this question.