Randy AC7NJ <[EMAIL PROTECTED]> writes:

> myfirst.c:5: error: 'cout' was not declared in this scope

Good.


> / / myfirst.c --displays a  message

If your example is from a textbook, that textbook must be pretty old.


> #include <iostream>
> int main(void)
> {
>       cout << "come up and C++ me sometime.";

The name cout isn't declared in the global namespace.

The header <iostream> declares the name cout in the namespace std,
though. E.g.:

        std::cout << "come up and C++ me sometime.";

would compile.
_______________________________________________
help-gplusplus mailing list
help-gplusplus@gnu.org
http://lists.gnu.org/mailman/listinfo/help-gplusplus

Reply via email to