Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8044243
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 5, 20262026-06-05T05:10:01+00:00 2026-06-05T05:10:01+00:00

I get these error messages for all cout and endl : main.cc:17:5: error: ‘cout’

  • 0

I get these error messages for all cout and endl:

main.cc:17:5: error: ‘cout’ was not declared in this scope
main.cc:17:5: note: suggested alternative:
/usr/include/c++/4.6/iostream:62:18: note:   ‘std::cout’

After following the suggestion, everything is fine. Now I am curious, why I had to do that. We used C++ in classes before, but I never had to write a std:: before any of those commands. What might be different on this system?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-05T05:10:02+00:00Added an answer on June 5, 2026 at 5:10 am

    It seems possible your class may have been using pre-standard C++. An easy way to tell, is to look at your old programs and check, do you see:

    #include <iostream.h>
    

    or

    #include <iostream>
    

    The former is pre-standard, and you’ll be able to just say cout as opposed to std::cout without anything additional. You can get the same behavior in standard C++ by adding

    using std::cout;
    

    or

    using namespace std;
    

    Just one idea, anyway.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Hello not sure why Im getting this error. Basically I get it in these
I get these errors messages all over the place for g++ 4.1.2, and it
Does anyone know what these error's mean? I get this when I click a
this is probably an include problem, i get these errors all over the code,
I get a number of browser error messages using ADFS, all of the form.
Sometimes I get this error message from time-based trigger of many scripts ... There
I get the following errors when I try to build this project: error C2182:
I'm trying to use this code, and these instructions to do direct messages. Posting
I get an exception with the message: There is an error in XML document.
I get these errors when I try to compile a matrix CUBLAS operation: 1>ClCompile:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.