Question: Why will the following code not compile? ` ` ` namespace ns 1 { void print ( ) ; void display 1 ( ) {
Why will the following code not compile?
namespace ns
void print;
void display;
namespace ns
void print;
void display ;
int main
using namespace ns;
using namespace ns;
display ;
display ;
print;
return ;
The call to print is ambiguous.
We have not included the iostream library.
We have not used namespace std
It will compile.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
