-
January 18th, 2004, 09:41 AM
#1
Every Hello World You Can Make!
I found a complete list of hello world functions, go now:
http://c2.com/cgi/wiki?HelloWorldInM...mmingLanguages
You shall no longer take things at second or third hand,
nor look through the eyes of the dead...You shall listen to all
sides and filter them for your self.
-Walt Whitman-
-
January 18th, 2004, 07:34 PM
#2
Code:
#include <iostream>
int main()
{
std::cout << "Hello, Ward." << std::endl;
}
thats the most screwy version of C++ hello world I have ever seen.... Not only does it not spell world properly, but whats with all the std:: crap...
\"Ignorance is bliss....
but only for your enemy\"
-- souleman
-
January 18th, 2004, 07:51 PM
#3
Well, cout is in the std namespace (as is endl), so technically you should use std::cout when you want to send data to the standard output.
Edit: Went on the Wiki and corrected the spelling mistake for you souleman.
-
January 18th, 2004, 08:08 PM
#4
I know its in means stdout, but who the hell actually programs like that?
\"Ignorance is bliss....
but only for your enemy\"
-- souleman
-
January 18th, 2004, 08:33 PM
#5
Me.
-
January 18th, 2004, 09:01 PM
#6
Yeah a lot of the diehard C++ programmers (*cough*pwaring*cough*) think that using
using namespace std;
completely destroys the purpose of having namespaces. I don't do it but If you want a page long explanation with charts, graphs, quotes, and a gif or two then ask pwaring all about it
You shall no longer take things at second or third hand,
nor look through the eyes of the dead...You shall listen to all
sides and filter them for your self.
-Walt Whitman-
-
January 18th, 2004, 10:08 PM
#7
pwaring> if you want a language that requires you to type all sorts of crap before you can output a line use java..
System.out.println is a lot longer then cout
\"Ignorance is bliss....
but only for your enemy\"
-- souleman
-
January 18th, 2004, 11:30 PM
#8
I use Java as well.
I just think that you should be explicit wherever possible in any language - the only exception to this being Perl because it's good enough for one-liners.
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
|
|