Help!
I have just started VC++ and am learning out of the book Visual C++ in 21 days. The book gave me this program to write and when I put it in Dev C++ and try to compile and run it keeps giving me these 5 errors- c:\mydocu~1\usingc~1.cpp: In function `int main()':
c:\mydocu~1\usingc~1.cpp:8: `Aendl' undeclared (first use this function)
c:\mydocu~1\usingc~1.cpp:8: (Each undeclared identifier is reported only once
c:\mydocu~1\usingc~1.cpp:8: for each function it appears in.)
If anyone could tell me what's wrong I would be highly appreciative. Oh yea and how do you get the source code into the white box when you post?
// Listing 2.2 using cout
#include <iostream.h>
int main()
{
cout << "Hello there.\n";
cout << "Here is 5: " << 5 << "\n";
Aendl;
cout << "The manipulator endl writes a new line to the screen." <<
cout << "Here is a very big number:\t" << 70000 << endl;
cout << "Here is the sum of 8 and 5:\t" << 8+5 << endl;
cout << "Here's a fraction:\t\t" << (float) 5/8 << endl;
cout << "And a very very big number:\t" << (double) 7000 * 7000 <<
Aendl;
cout << "Don't forget to replace Jessie Liberty with your name...\n";
cout << "Jessie Liberty is a C++ programmer!\n";
return 0;
}
[edited by - Noxxid on April 6, 2002 2:32:19 PM]
[edited by - Noxxid on April 6, 2002 2:36:35 PM]
[edited by - Noxxid on April 6, 2002 3:46:01 PM]
[edited by - Noxxid on April 6, 2002 3:55:21 PM]
"Classes will dull your mind destroy the potential for authentic creativity"
quote: Original post by Noxxid
Aendl;
There''s your bug.
[ GDNet Start Here | GDNet Search Tool | GDNet FAQ | MS RTFM [MSDN] | SGI STL Docs | Google! | Asking Smart Questions ]
Thanks to Kylotan for the idea!
yay thanks so much it works! the book doesnt say not to put them in there
"Classes will dull your mind destroy the potential for authentic creativity"
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement