Forum     

Go Back   Digit Technology Discussion Forum > Software > Programming
Register FAQ Calendar Mark Forums Read

Programming The destination for developers - C, C++, Java, Python and the lot


View Poll Results: What is your preferred language?
C - GNU C, Borland C,.... 2 15.38%
C++, Visual C++, g++.... 4 30.77%
Java 1 7.69%
C#.NET 2 15.38%
PHP 0 0%
VB.NET 2 15.38%
Python 2 15.38%
Perl 0 0%
Ruby 0 0%
Cobol 0 0%
Voters: 13. You may not vote on this poll

Closed Thread
 
LinkBack Thread Tools Display Modes
Old 09-05-2009, 09:41 PM   #1 (permalink)
Always confused
 
vamsi360's Avatar
 
Join Date: May 2008
Location: Mandriva Control Center
Posts: 349
Smile The Official Hello world thread!.....


C:
Code:
 #include int main() {     printf("Hello world!"); }
__________________
Vamsi Subhash
visit my blog at www.vamsisubhash.co.cc and taste a bit of IT!
vamsi360 is offline  
Advertisements. Register and be a member of the community to get rid of them.
Advertisement

Old 09-05-2009, 09:47 PM   #2 (permalink)
Sami Hyypiä, LFC legend
 
Liverpool_fan's Avatar
 
Join Date: Jun 2007
Location: Нью-Дели
Posts: 2,138
Default Re: The Official Hello world thread!.....

Python:

Code:
print "Hello World"
Or More structural:

Code:
def main():
	print "Hello World"
	
if __name__=='__main__':
	main()
Ruby:
Code:
puts "Hello World"
__________________
Experience true education in Computer Science - http://www.udacity.com | http://www.coursera.org

Spoiler:
Read before asking / messaging any moderator for any query: FAQ + answers for new members

Read all the sticky threads before asking any type of query. Most basic questions are answered in those.
Don't use forum for chatting. Visit http://webchat.freenode.net/?channels=krow, enter nick and connect.

Last edited by Liverpool_fan; 09-05-2009 at 09:55 PM.
Liverpool_fan is offline  
Old 12-05-2009, 04:03 PM   #3 (permalink)
Call me D_J!
 
Disc_Junkie's Avatar
 
Join Date: Nov 2008
Location: INDIA
Posts: 866
Default Re: The Official Hello world thread!.....

JAVA

Code:

class HelloWorld
{
           public static void main()
           {
           System.out.println("Hello World");
           }
}

C++



Code:
#include<iostream.h>
#include<conio.h>
void main()
        {
         cout<<"Hello World";
         getch();
        }
__________________
ASUS K42JA-VX032D RAWKS !!!!!!:grin:

Last edited by Disc_Junkie; 12-05-2009 at 04:11 PM.
Disc_Junkie is offline  
Old 12-05-2009, 07:54 PM   #4 (permalink)
-----ATi-----
 
nvidia's Avatar
 
Join Date: May 2007
Location: Bangalore
Posts: 2,322
Default Re: The Official Hello world thread!.....

C#:
Code:
namespace Hello_World
{
    class Program
    {
        static void Main(string[] args)
        {
            System.Console.Write("Hello World");
        }
    }
}
__________________
http://twitter.com/akshayms
nvidia is offline  
Old 12-05-2009, 08:04 PM   #5 (permalink)
Sami Hyypiä, LFC legend
 
Liverpool_fan's Avatar
 
Join Date: Jun 2007
Location: Нью-Дели
Posts: 2,138
Default Re: The Official Hello world thread!.....

Quote:
Originally Posted by Disc_Junkie View Post
[



C++



Code:
#include<iostream.h>
#include<conio.h>
void main()
        {
         cout<<"Hello World";
         getch();
        }
Er..um..this is not exactly according to standards. This is actually Turbo C++ taught in schools and colleges in India.
Anyway it should be

Code:
#include<iostream>

int main()
{
       std::cout<<"Hello World";
       return 0;
}
Quote:
Originally Posted by Disk_Junkie
Code:

class HelloWorld
{
           public static void main()
           {
           System.out.println("Hello World");
           }
}
Shouldn't there be String[] arguments in main()? (I know a crap about java but I think Java requires arguments for main as such)
__________________
Experience true education in Computer Science - http://www.udacity.com | http://www.coursera.org

Spoiler:
Read before asking / messaging any moderator for any query: FAQ + answers for new members

Read all the sticky threads before asking any type of query. Most basic questions are answered in those.
Don't use forum for chatting. Visit http://webchat.freenode.net/?channels=krow, enter nick and connect.

Last edited by Liverpool_fan; 12-05-2009 at 08:12 PM.
Liverpool_fan is offline  
Old 12-05-2009, 09:57 PM   #6 (permalink)
Call me D_J!
 
Disc_Junkie's Avatar
 
Join Date: Nov 2008
Location: INDIA
Posts: 866
Default Re: The Official Hello world thread!.....

Quote:
Originally Posted by Liverpool_fan View Post
Er..um..this is not exactly according to standards. This is actually Turbo C++ taught in schools and colleges in India.
Anyway it should be

Code:
#include<iostream>

int main()
{
       std::cout<<"Hello World";
       return 0;
}
You used the int return type and I used void. Yup I coded it according to Turbo C++. But thanks for your example...

Quote:
Originally Posted by Liverpool_fan View Post
Shouldn't there be String[] arguments in main()? (I know a crap about java but I think Java requires arguments for main as such)
It isn't necessary as such(as the program will still compile) but yup it's worth mentioning...
__________________
ASUS K42JA-VX032D RAWKS !!!!!!:grin:
Disc_Junkie is offline  
Old 12-05-2009, 10:39 PM   #7 (permalink)
Sami Hyypiä, LFC legend
 
Liverpool_fan's Avatar
 
Join Date: Jun 2007
Location: Нью-Дели
Posts: 2,138
Default Re: The Official Hello world thread!.....

Quote:
Originally Posted by Disc_Junkie View Post
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:
http://www.gidnetwork.com/b-66.html
__________________
Experience true education in Computer Science - http://www.udacity.com | http://www.coursera.org

Spoiler:
Read before asking / messaging any moderator for any query: FAQ + answers for new members

Read all the sticky threads before asking any type of query. Most basic questions are answered in those.
Don't use forum for chatting. Visit http://webchat.freenode.net/?channels=krow, enter nick and connect.
Liverpool_fan is offline  
Old 12-05-2009, 10:57 PM   #8 (permalink)
Call me D_J!
 
Disc_Junkie's Avatar
 
Join Date: Nov 2008
Location: INDIA
Posts: 866
Default Re: The Official Hello world thread!.....

Quote:
Originally Posted by Liverpool_fan View Post
It's Actually it's for a reason:
http://www.gidnetwork.com/b-66.html
Thanks for the info!
__________________
ASUS K42JA-VX032D RAWKS !!!!!!:grin:
Disc_Junkie is offline  
Old 15-05-2009, 11:14 PM   #9 (permalink)
Evolving Rapidly...
 
confused's Avatar
 
Join Date: Mar 2008
Location: Bombay <---> BIT Mesra
Posts: 514
Default Re: The Official Hello world thread!.....

Quote:
Originally Posted by Liverpool_fan View Post
It's Actually it's for a reason:
http://www.gidnetwork.com/b-66.html
thanks for the link.
__________________
http://qbitmesra.blogspot.com - Quenching BIT's Quriosity

"Female sexuality isnt a myth" - what i learnt in my first year at college
confused is offline  
Old 02-06-2009, 07:41 PM   #10 (permalink)
Always confused
 
vamsi360's Avatar
 
Join Date: May 2008
Location: Mandriva Control Center
Posts: 349
Smile Re: The Official Hello world thread!.....

in C#:

Code:
using System;
class HelloWorld  {
     static void Main()  {
           Console.WriteLine("Hello, World!");
     }
}
in PHP:

Code:
<?php
echo "Hello, World!";
?>
__________________
Vamsi Subhash
visit my blog at www.vamsisubhash.co.cc and taste a bit of IT!
vamsi360 is offline  
Old 04-06-2009, 04:52 PM   #11 (permalink)
Sami Hyypiä, LFC legend
 
Liverpool_fan's Avatar
 
Join Date: Jun 2007
Location: Нью-Дели
Posts: 2,138
Default Re: The Official Hello world thread!.....

Ruby
Code:
#!/usr/bin/env ruby
puts "Hello World"
D
Code:
import std.stdio;

int main(char[][] args)
{
    writefln("Hello World");
    return 0;
}
__________________
Experience true education in Computer Science - http://www.udacity.com | http://www.coursera.org

Spoiler:
Read before asking / messaging any moderator for any query: FAQ + answers for new members

Read all the sticky threads before asking any type of query. Most basic questions are answered in those.
Don't use forum for chatting. Visit http://webchat.freenode.net/?channels=krow, enter nick and connect.

Last edited by Liverpool_fan; 04-06-2009 at 05:05 PM.
Liverpool_fan is offline  
Old 04-06-2009, 06:28 PM   #12 (permalink)
Wise Old Owl
 
hullap's Avatar
 
Join Date: Dec 2006
Location: delhi
Posts: 1,429
Default Re: The Official Hello world thread!.....

LOLCODE
Code:
HAI
CAN HAS STDIO?
VISIBLE "HAI WORLD!"
KTHXBYE
hullap is offline  
Old 04-06-2009, 08:02 PM   #13 (permalink)
ico
.
 
ico's Avatar
 
Join Date: Jun 2007
Location: New Delhi
Posts: 8,923
Default Re: The Official Hello world thread!.....

niaaaaaa
__________________
.
ico is offline  
Old 04-06-2009, 09:47 PM   #14 (permalink)
Banned
 
Join Date: Jan 2009
Location: Un monde utopique
Posts: 452
Default Re: The Official Hello world thread!.....

^^
Niaaaaaaa???????

Surely you don't mean this
Crazykiller is offline  
Old 04-06-2009, 10:04 PM   #15 (permalink)
damnbadman666
 
damngoodman999's Avatar
 
Join Date: Nov 2008
Location: Coimbatore
Posts: 2,590
Default Re: The Official Hello world thread!.....

C:

# define

void main ()

{

printf ("ram says hello to all"\n);

}
__________________
AMD Phenom 2 940 @ 3.4Ghz [Hyper 212+] :arrow: MA790GP-UD4H :arrow: OCZ DDR2 2x2GB :arrow: Asus GTX 560ti :bananana::arrow: 1TB SATA2 :arrow: LG 20" LED :arrow: Razer DA mice :arrow: RED HOT cabby
damngoodman999 is offline  
Closed Thread

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


 
Latest Threads
- by Sujeet
- by gforz
- by soumya

Advertisement




All times are GMT +5.5. The time now is 03:13 PM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.

Search Engine Optimization by vBSEO 3.3.2