Author Topic: "Hello World" Series  (Read 22422 times)

Celestial_Rage

  • Posts: 636
  • Turrets: +120/-8
Re: "Hello World" Series
« Reply #30 on: November 01, 2009, 02:24:49 am »
Code: [Select]
#!/bin/bash
echo "Hello, world"
exit 0

Aww, I was going to use bash :(

Oh well, FoxProx, works fine..

Code: [Select]
print "Hello World"
end
"The reports of my death are greatly exaggerated" ~Mark Twain

KillerWhale

  • Spam Killer
  • *
  • Posts: 469
  • Turrets: +63/-26
Re: "Hello World" Series
« Reply #31 on: November 01, 2009, 06:58:12 pm »
Code: [Select]
Disp "HELLO WORLD"
OWNED TI-BASIC!

Cadynum

  • Posts: 222
  • Turrets: +29/-13
Re: "Hello World" Series
« Reply #32 on: November 01, 2009, 08:48:09 pm »
Code: [Select]
main = putStrLn "Hello World"

gimhael

  • Posts: 546
  • Turrets: +70/-16
Re: "Hello World" Series
« Reply #33 on: November 01, 2009, 10:22:38 pm »
Code: [Select]
main = putStrLn.unwords$["Hello","World"]

MitSugna

  • Guest
Re: "Hello World" Series
« Reply #34 on: November 03, 2009, 10:16:14 am »
hell = require('helloWorld')
if hell =~ nil then hell.run()
else print('Hello World')
end

A Spork

  • Spam Killer
  • *
  • Posts: 1010
  • Turrets: +37/-230
    • Spork - Unvanquished.net
Re: "Hello World" Series
« Reply #35 on: November 03, 2009, 08:35:03 pm »
#include <iostream.h>
 
void main()
{
    cout << "Hello, world!";
}
Don't shoot friend :basilisk:! Friend :basilisk: only wants to give you hugz and to be your hat

Proud Member of the S.O.B.F.O.B.S.A.D: The Society Of Basilisks For Other Basilisks Safety and Dominance
:basilisk:    :basilisk:    :basilisk:

Amanieu

  • Posts: 647
  • Turrets: +135/-83
    • Amanieu
Re: "Hello World" Series
« Reply #36 on: November 03, 2009, 08:58:08 pm »
STOP ABUSING THE BIT SHIFT OPERATOR >:(
Quote
< kevlarman> zakk is getting his patches from shady frenchmen on irc
< kevlarman> this can't be a good sign :P

AppleJuice

  • Posts: 475
  • Turrets: +94/-160
Re: "Hello World" Series
« Reply #37 on: November 04, 2009, 07:00:53 pm »
#include <iostream>

int main() {
   std::cout << "Hello, world!\n";
}

Fixed
Currently: {&}AppleJuice

A Spork

  • Spam Killer
  • *
  • Posts: 1010
  • Turrets: +37/-230
    • Spork - Unvanquished.net
Re: "Hello World" Series
« Reply #38 on: November 04, 2009, 07:17:43 pm »
Mine is C++, and it works.
(And your version fails btw, no return statement)
« Last Edit: November 04, 2009, 07:21:06 pm by A Spork »
Don't shoot friend :basilisk:! Friend :basilisk: only wants to give you hugz and to be your hat

Proud Member of the S.O.B.F.O.B.S.A.D: The Society Of Basilisks For Other Basilisks Safety and Dominance
:basilisk:    :basilisk:    :basilisk:

AppleJuice

  • Posts: 475
  • Turrets: +94/-160
Re: "Hello World" Series
« Reply #39 on: November 04, 2009, 07:20:57 pm »
Meh, it works either way.
(And your version fails btw, no return statement)

No.
http://www2.research.att.com/~bs/bs_faq2.html
http://www2.research.att.com/~bs/bs_faq2.html#void-main

"In C++, main() need not contain an explicit return statement. In that case, the value returned is 0, meaning successful execution."
This also includes reasons as to why your version is not good.

There's some reading for you. :)

Btw, your version doesn't compile with g++ -ansi -pedantic -Wall
Currently: {&}AppleJuice

A Spork

  • Spam Killer
  • *
  • Posts: 1010
  • Turrets: +37/-230
    • Spork - Unvanquished.net
Re: "Hello World" Series
« Reply #40 on: November 04, 2009, 07:29:09 pm »
whatever.
It worked for me, and thats what I was taught.
Don't shoot friend :basilisk:! Friend :basilisk: only wants to give you hugz and to be your hat

Proud Member of the S.O.B.F.O.B.S.A.D: The Society Of Basilisks For Other Basilisks Safety and Dominance
:basilisk:    :basilisk:    :basilisk:

AppleJuice

  • Posts: 475
  • Turrets: +94/-160
Re: "Hello World" Series
« Reply #41 on: November 04, 2009, 08:32:10 pm »
Worked in which programming environment?
Currently: {&}AppleJuice

A Spork

  • Spam Killer
  • *
  • Posts: 1010
  • Turrets: +37/-230
    • Spork - Unvanquished.net
Re: "Hello World" Series
« Reply #42 on: November 04, 2009, 09:56:53 pm »
C++
Couldn't tell you what program off the top of my head....
Don't shoot friend :basilisk:! Friend :basilisk: only wants to give you hugz and to be your hat

Proud Member of the S.O.B.F.O.B.S.A.D: The Society Of Basilisks For Other Basilisks Safety and Dominance
:basilisk:    :basilisk:    :basilisk:

AppleJuice

  • Posts: 475
  • Turrets: +94/-160
Re: "Hello World" Series
« Reply #43 on: November 04, 2009, 10:17:05 pm »
C++

Dude, I obviously know it's C++...



someone use a Visual Basic GUI to track the IP
Currently: {&}AppleJuice

3of12

  • Posts: 45
  • Turrets: +7/-16
Re: "Hello World" Series
« Reply #44 on: November 04, 2009, 11:28:31 pm »
Scratch that, wrong problem.

IabzO.o

  • Posts: 258
  • Turrets: +29/-67
Re: "Hello World" Series
« Reply #45 on: November 05, 2009, 02:00:31 am »
C++

Dude, I obviously know it's C++...



someone use a Visual Basic GUI to track the IP

imsrybrobutitsnotsoobvious
POWA SUKC AT TRMELUS

I AM JESUS

MitSugna

  • Guest
Re: "Hello World" Series
« Reply #46 on: November 05, 2009, 04:06:23 am »
#include <iostream>

int main() {
   std::cout << "Hello, world!" << std::endl;
   return 0;
}

Fixed
Dunno if fixed or correct but that is what I'd do
( Also using std::endl instead of '\\n' makes you look cooler :P )

Bajsefar

  • Posts: 597
  • Turrets: +49/-39
Re: "Hello World" Series
« Reply #47 on: November 15, 2009, 01:50:58 am »
Hallo verden.