C:
Code:
#include int main() { printf("Hello world!"); }
#include int main() { printf("Hello world!"); }
print "Hello World"
def main():
print "Hello World"
if __name__=='__main__':
main()
puts "Hello World"
[FONT="][B]
[/B][/FONT]class HelloWorld
{
public static void main()
{
System.out.println("Hello World");
}
}
#include<iostream.h>
#include<conio.h>
void main()
{
cout<<"Hello World";
getch();
}
namespace Hello_World
{
class Program
{
static void Main(string[] args)
{
System.Console.Write("Hello World");
}
}
}
#include<iostream>
int main()
{
std::cout<<"Hello World";
return 0;
}
Shouldn't there be String[] arguments in main()? (I know a crap about java but I think Java requires arguments for main as such)Disk_Junkie said:
You used the int return type and I used void. Yup I coded it according to Turbo C++. But thanks for your example...
It's Actually it's for a reason:
thanks for the link.
using System;
class HelloWorld {
static void Main() {
Console.WriteLine("Hello, World!");
}
}
<?php
echo "Hello, World!";
?>
#!/usr/bin/env ruby
puts "Hello World"
import std.stdio;
int main(char[][] args)
{
writefln("Hello World");
return 0;
}
HAI
CAN HAS STDIO?
VISIBLE "HAI WORLD!"
KTHXBYE