|
-
Jul 3rd, 2006, 06:52 AM
#1
Thread Starter
Hyperactive Member
New to C++
I just got hold of Visual C++ 6 and i am trying the followinf code. The only problem is the compiler says i have 1 error but i'm not sure where.
Here is the code.
Code:
#Include <iostream>
Using namespace std;
int main()
{
int intNumber;
cout << "Please enter a number";
cin >> intNumber;
if (intNumber > 10)
{
cout << "The Number is bigger than 10";
}
else
{
cout << "The number is less than 10";
}
return 0;
}
Any ideas on what the problem is
Jenova
-
Jul 3rd, 2006, 08:49 AM
#2
Lively Member
Re: New to C++
Code:
#Include <iostream.h>
Instead of
Code:
#Include <iostream>
I think.. 
And doesn't the compiler specify the line where the error was found, and a description?
-
Jul 3rd, 2006, 08:57 AM
#3
Re: New to C++
#include
using
Otherwise it looks fine to me.
Double click the error in the Build output window to jump to the offending line.
-
Jul 5th, 2006, 04:23 AM
#4
Re: New to C++
VC++6 is bad and outdated. Look for a better one.
Aside from that, what penagate said. (C++ is case sensitive) And definitely not what Guiseppe said.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|