Error: "cout" is ambiguous.

what do i do to take the red squiggly out from under the cout word when it says it is ambiguous?
post some code.

You probably
A) Forgot #include <string>
B) declared a variable called cout
closed account (3qX21hU5)
Removed because of bad info
Last edited on
closed account (zb0S216C)
Ambiguities will not be the result of neither failing to include "iostream", nor will it be the result of not declaring the said identifier. These errors, in your case, means the compiler was not able to choose one of the overloaded "ostream::operator << ( )" operators based on the actual parameter. In other words, the actual parameter given to "std::cout" was compatible (convertible) with two or more overloads of its "operator << ( )" and, therefore, was not able to choose which overload to call; thus, ambiguity.

Wazzak
Topic archived. No new replies allowed.