Why will the following code not compile?

namespace ns1
{
void print();
void display1(){};
}

namespace ns2
{
void print();
void display2(){};
}

int main()
{
using namespace ns1;
using namespace ns2;
display1();
display2();
print();
return 0;
}
a. The call to print is ambiguous
b. We have not included the iostream library
c. We have not used namespace std
d. It will compile

a. The call to print is ambiguous

Computer Science & Information Technology

You might also like to view...

In Project 2013, a project can only be scheduled by Start date or Finish date, not by both

Indicate whether the statement is true or false

Computer Science & Information Technology

You are not required to provide a language description in an XHTML page

Indicate whether the statement is true or false

Computer Science & Information Technology