Hello world/Text

From Rosetta Code
< Hello world(Redirected from Hello world)
Task
Hello world/Text
You are encouraged to solve this task according to the task description, using any language you may know.
Hello world/Text is part of Short Circuit's Console Program Basics selection.

In this User Output task, the goal is to display the string "Hello world!" [sic] on a text console.

See also


Contents

0815[edit]

 
<:48:x<:65:=<:6C:$=$=$$~<:03:+
$~<:ffffffffffffffb1:+$<:77:~$
~<:fffffffffffff8:x+$~<:03:+$~
<:06:x-$x<:0e:x-$=x<:43:x-$
 
 

360 Assembly[edit]

Using native SVC (Supervisor Call) to write to system console:

         LA    1,MSGAREA     Point Register 1 to message area
SVC 35 Invoke SVC 35 (Write to Operator)
BR 14 Return
MSGAREA EQU * Message Area
DC AL2(19) Total area length = 19 (Prefix length:4 + Data Length:15)
DC XL2'00' 2 bytes binary of zeros
DC C'Hello world!' Text to be written to system console
END

Using WTO Macro to generate SVC 35 and message area:

         WTO   'Hello world!'
BR 14 Return
END

4DOS Batch[edit]

echo Hello world!

6502 Assembly[edit]

; goodbyeworld.s for C= 8-bit machines, ca65 assembler format.
; String printing limited to strings of 256 characters or less.
 
a_cr = $0d ; Carriage return.
bsout = $ffd2 ; KERNAL ROM, output a character to current device.
 
.code
 
ldx #0 ; Starting index 0 in X register.
printnext:
lda text,x ; Get character from string.
beq done ; If we read a 0 we're done.
jsr bsout ; Output character.
inx ; Increment index to next character.
bne printnext ; Repeat if index doesn't overflow to 0.
done:
rts ; Return from subroutine.
 
.rodata
 
text:
.byte "Hello world!", a_cr, 0

6800 Assembly[edit]

        .cr  6800
.tf gbye6800.obj,AP1
.lf gbye6800
;=====================================================;
; Hello world! for the Motorola 6800  ;
; by barrym 2013-03-17  ;
;-----------------------------------------------------;
; Prints the message "Hello world!" to an ascii  ;
; terminal (console) connected to a 1970s vintage  ;
; SWTPC 6800 system, which is the target device for ;
; this assembly.  ;
; Many thanks to:  ;
; swtpc.com for hosting Michael Holley's documents! ;
; sbprojects.com for a very nice assembler!  ;
; swtpcemu.com for a very capable emulator!  ;
; reg x is the string pointer  ;
; reg a holds the ascii char to be output  ;
;-----------------------------------------------------;
outeee = $e1d1  ;ROM: console putchar routine
.or $0f00
;-----------------------------------------------------;
main ldx #string  ;Point to the string
bra puts  ; and print it
outs jsr outeee  ;Emit a as ascii
inx  ;Advance the string pointer
puts ldaa ,x  ;Load a string character
bne outs  ;Print it if non-null
swi  ; else return to the monitor
;=====================================================;
string .as "Hello world!",#13,#10,#0
.en

8086 Assembly[edit]

DOSSEG
.MODEL TINY
.DATA
TXT DB "Hello world!$"
.CODE
START:
MOV ax, @DATA
MOV ds, ax
 
MOV ah, 09h ; prepare output function
MOV dx, OFFSET TXT ; set offset
INT 21h ; output string TXT
 
MOV AX, 4C00h ; go back to DOS
INT 21h
END START

With A86 or NASM syntax:

  org 100h

  mov dx, msg
  mov ah, 9
  int 21h

  mov ax, 4c00h
  int 21h

msg:
  db "Hello world!$"

8th[edit]

"Hello world!\n" . bye

ABAP[edit]

REPORT zgoodbyeworld.
WRITE 'Hello world!'.

ACL2[edit]

(cw "Hello world!~%")

ActionScript[edit]

trace("Hello world!");

Ada[edit]

Works with: GCC version 4.1.2
with Ada.Text_IO; use Ada.Text_IO;
procedure Main is
begin
Put_Line ("Hello world!");
end Main;

Aime[edit]

o_text("Hello world!\n");

or:

integer
main(void)
{
o_text("Hello world!\n");
 
return 0;
}

Algae[edit]

printf("Hello world!\n");

ALGOL 60[edit]

'BEGIN'
OUTSTRING(1,'('Hello world!')');
SYSACT(1,14,1)
'END'

ALGOL 68[edit]

main: (
printf($"Hello world!"l$)
)

ALGOL W[edit]

begin
write( "Hello world!" )
end.

Alore[edit]

Print('Hello world!')

AmbientTalk[edit]

system.println("Hello world!")

AmigaE[edit]

PROC main()
WriteF('Hello world!\n')
ENDPROC

AppleScript[edit]

To show in Script Editor Result pane:

"Hello world!"

To show in Script Editor Event Log pane:

log "Hello world!"

Applesoft BASIC[edit]

Important Note: Although Applesoft BASIC allowed the storage and output of mixed-case strings, the ability to enter mixed-case via the keyboard and to output mixed-case on the default display was not offered as standard equipment on the original Apple II/II+. Since Applesoft WAS the default programming language for the Apple II+, perhaps some flexibility in the task specification could be offered, for this and for other systems that lacked proper mixed-case I/O capabilities in at least one popular configuration.

 PRINT "Hello world!"

Apricot[edit]

(puts "Hello world!")

Arendelle[edit]

"Hello world!"

Argile[edit]

use std
print "Hello world!"

compile with: arc hello_world.arg -o hello_world.c && gcc -o hello_world hello_world.c

ARM Assembly[edit]

.global main
 
message:
.asciz "Hello world!\n"
.align 4
 
main:
ldr r0, =message
bl printf
 
mov r7, #1
swi 0

Asymptote[edit]

write('Hello world!');

ATS[edit]

implement main0 () = print "Hello world!\n"

AutoHotkey[edit]

script launched from windows explorer

DllCall("AllocConsole")
FileAppend, Goodbye`, World!, CONOUT$
FileReadLine, _, CONIN$, 1

scripts run from shell [requires Windows XP or higher; older Versions of Windows don´t have the "AttachConsole" function]

DllCall("AttachConsole", "int", -1)
FileAppend, Goodbye`, World!, CONOUT$
SendInput Hello world!{!}

AutoIt[edit]

ConsoleWrite("Hello world!" & @CRLF)

AutoLISP[edit]

(printc "Hello World!")

AWK[edit]

BEGIN{print "Hello world!"}


"BEGIN" is a "special pattern" - code within "{}" is executed before the input file is read, even if there is no input. "END" is a similar pattern, for after completion of main processing.

 
END {
print "Hello world!"
}
 

For a file containing data, the work can be done in the "body". The "//" is "match anything" so gets the first data, the "exit" halts processing the file (any "END" would then be executed).

 
// {
print "Hello world!"
exit
}
 


For a "single record" file.

 
// {
print "Hello world!"
}
 

For a "single record" file containing - Hello world! -. The "default" action for a "pattern match" (the "/" and "/" define a "pattern" to match data) is to "print" the record.

 
//
 

Axe[edit]

Note that the i here is the imaginary i, not the lowercase letter i.

Disp "Hello world!",i

Babel[edit]

((main { "Hello world!" << }))

bash[edit]

echo "Hello world!"

BASIC[edit]

Works with: BASICA
Works with: Locomotive Basic
Works with: ZX Spectrum Basic
10 PRINT "Hello world!"
Works with: 7Basic
Works with: QBasic
PRINT "Hello world!"

BASIC256[edit]

PRINT "Hello world!"

Batch File[edit]

Under normal circumstances, when delayed expansion is disabled

echo Hello world!

If delayed expansion is enabled, then the ! must be escaped twice

setlocal enableDelayedExpansion
echo Hello world!^^!

Battlestar[edit]

const hello = "Hello world!\n"
 
print(hello)

BBC BASIC[edit]

      PRINT "Hello world!"

bc[edit]

"Hello world!
"

BCPL[edit]

GET "libhdr"
 
LET start() = VALOF
{ writef("Hello world!")
RESULTIS 0
}

Beeswax[edit]

Straightforward:

*`Hello, World!

Less obvious way:

 
>`ld!
`
r
o
W
`
b` ,olleH`_
 

Befunge[edit]

52*"!dlroW ,eybdooG">:#,_@

Blast[edit]

# This will display a goodbye message on the terminal screen
.begin
display "Hello world!"
return
# This is the end of the script.

BML[edit]

display "Hello world!"

Boo[edit]

print "Hello world!"

Brace[edit]

#!/usr/bin/env bx
use b
Main:
say("Hello world!")

Bracmat[edit]

put$"Hello world!"

Brainf***[edit]

To print text, we need the ascii-value of each character to output.
So, we wanna make a series of round numbers going like:

10	close to newline and carriage return
30	close to ! and SPACE
40	close to COMMA
70	close to G
80	close to W
90	close to b
100	is d and close to e and l
110	close to o
120	close to y

forming all the letters we need if we just add up a bit

Commented version:

+++++ +++++		First cell 10 (its a counter and we will be "multiplying")
 
[
>+ 10 times 1 is 10
>+++ 10 times 3 is 30
>++++ etc etc
>+++++ ++
>+++++ +++
>+++++ ++++
>+++++ +++++
>+++++ ++++++
>+++++ +++++++
<<<<<<<<< - go back to counter and subtract 1
]
 
printing G
>>>> + .
 
o twice
>>>> + ..
 
d
< .
 
b
< +++++ +++ .
 
y
>>> + .
 
e
<< + .
 
COMMA
<<<< ++++ .
 
SPACE
< ++ .
 
W
>>> +++++ ++ .
 
o
>>> .
 
r
+++ .
 
l
< +++++ ++ .
 
d
----- --- .
 
!
<<<<< + .
 
CRLF
< +++ . --- .

Uncommented:

++++++++++[>+>+++>++++>+++++++>++++++++>+++++++++>++
++++++++>+++++++++++>++++++++++++<<<<<<<<<-]>>>>+.>>>
>+..<.<++++++++.>>>+.<<+.<<<<++++.<++.>>>+++++++.>>>.+++.
<+++++++.--------.<<<<<+.<+++.---.

It can most likely be optimized, but this is a nice way to show how character printing works in Brainf*** :)

Brat[edit]

p "Hello world!"

Brlcad[edit]

The mged utility can output text to the terminal:

 
echo Hello world!
 

Burlesque[edit]

 
"Hello world!"sh
 

Although please note that sh actually does not print anything.

C[edit]

Works with: gcc version 4.0.1
#include <stdlib.h>
#include <stdio.h>
 
int main(void)
{
printf("Hello world!\n");
return EXIT_SUCCESS;
}

Or:

#include <stdlib.h>
#include <stdio.h>
 
int main(void)
{
puts("Hello world!");
return EXIT_SUCCESS;
}

Or, the eternal favourite :)

 
#include<stdio.h>
 
int main()
{
printf("\nHello world!");
return 0;
}

C#[edit]

Works with: Mono version 1.2
Works with: Visual C# version 2003
namespace HelloWorld
{
class Program
{
static void Main(string[] args)
{
System.Console.WriteLine("Hello world!");
}
}
}

C++[edit]

#include <iostream>
 
int main () {
std::cout << "Hello world!" << std::endl;
}

C++/CLI[edit]

using namespace System;
int main()
{
Console::WriteLine("Hello world!");
}

C1R[edit]

Hello_world/Text
Output:
$ echo Hello_world/Text >hw.c1r
$ ./c1r hw.c1r
$ ./a.out
Hello world!

Cat[edit]

"Hello world!" writeln

Cduce[edit]

print "Hello world!";;

Chef[edit]

Goodbye World Souffle.
 
Ingredients.
71 g green beans
111 cups oil
98 g butter
121 ml yogurt
101 eggs
44 g wheat flour
32 zucchinis
119 ml water
114 g red salmon
108 g lard
100 g dijon mustard
33 potatoes
 
Method.
Put potatoes into the mixing bowl.
Put dijon mustard into the mixing bowl.
Put lard into the mixing bowl.
Put red salmon into the mixing bowl.
Put oil into the mixing bowl.
Put water into the mixing bowl.
Put zucchinis into the mixing bowl.
Put wheat flour into the mixing bowl.
Put eggs into the mixing bowl.
Put yogurt into the mixing bowl.
Put butter into the mixing bowl.
Put dijon mustard into the mixing bowl.
Put oil into the mixing bowl.
Put oil into the mixing bowl.
Put green beans into the mixing bowl.
Liquefy contents of the mixing bowl.
Pour contents of the mixing bowl into the baking dish.
 
Serves 1.

ChucK[edit]

<<< "Hello world!">>>;

Clay[edit]

main() {
println("Hello world!");
}

Clean[edit]

Start = "Hello world!"

Clipper[edit]

? "Hello world!"

CLIPS[edit]

(printout t "Hello world!" crlf)

Clojure[edit]

(println "Hello world!")

CMake[edit]

message(STATUS "Hello world!")

This outputs

-- Hello world!

COBOL[edit]

Using fixed format.

Works with: OpenCOBOL
	program-id. hello.
procedure division.
display "Hello world!".
stop run.

Cobra[edit]

class Hello
def main
print 'Hello world!'

CoffeeScript[edit]

Works with: Node.js
console.log "Hello world!"
Works with: Rhino engine
print "Hello world!"

ColdFusion[edit]

<cfoutput>Hello world!</cfoutput>

Common Lisp[edit]

(format t "Hello world!~%")

Or

(print "Hello world!")

Component Pascal[edit]

 
MODULE Hello;
IMPORT Out;
 
PROCEDURE Do*;
BEGIN
Out.String("Hello world!"); Out.Ln
END Do;
END Hello.

Run command Hello.Do by commander.

Crack[edit]

 
import crack.io cout;
cout `Hello world!\n`;
 

Creative Basic[edit]

 
OPENCONSOLE
 
PRINT"Hello world!"
 
'This line could be left out.
PRINT:PRINT:PRINT"Press any key to end."
 
'Keep the console from closing right away so the text can be read.
DO:UNTIL INKEY$<>""
 
CLOSECONSOLE
 
END
 

Crystal[edit]

puts "Hello world!"

D[edit]

Works with: D version 2.0
import std.stdio;
 
void main() {
writeln("Hello world!");
}

Dao[edit]

io.writeln( 'Hello world!' )

Dart[edit]

main() {
var bye = 'Hello world!';
print("$bye");
}

dc[edit]

[Hello world!]p

DCL[edit]

$ write sys$output "Hello world!"

DDNC[edit]

DDNC can only output to a single 7-segment LED display digit, so first we must convert each character into its 7-segment equivalent numerical value.

The three horizontal bars are assigned bits 6, 3, and 0 from top to bottom. The top two vertical bars are assigned bits 5 and 4 while the bottom two vertical bars are assigned bits 2 and 1 from left to right.

Because DDNC can only interpret literals in decimal, each binary number was converted and stored in consecutive memory cells starting at cell 10.

The code can be divided into three sections. The first stores the character numbers in order in an array. The second sets up the loop by loading a delay of 500 milliseconds to slot 3, the start address of the character array in memory to slot 2, and the number of times to loop (14) plus one to slot 5. The third section starts the loop of displaying the characters, waiting for the delay time, incrementing the pointer, decrementing the counter, and checking if the counter is negative to know whether to continue the loop.

 
0 111 10
0 15 11
0 15 12
0 31 13
0 47 14
0 59 15
0 125 16
0 3 17
0 0 18
0 63 19
0 15 20
0 12 21
0 36 22
0 31 23
0 17 24
 
0 500 3
0 10 2
0 15 5
 
60 4
2 2 1
80 1
72 3
30 2
31 5
62 5
61 4
64
 

Déjà Vu[edit]

!print "Hello world!"

Delphi[edit]

 
program ProjectGoodbye;
{$APPTYPE CONSOLE}
begin
WriteLn('Hello world!');
end.
 

DWScript[edit]

 
PrintLn('Hello world!');
 

Dylan[edit]

 
module: hello-world
 
format-out("%s\n", "Hello world!");
 

Dylan.NET[edit]

Works with: Mono version 2.6.7
Works with: Mono version 2.10.x
Works with: Mono version 3.x.y
Works with: .NET version 3.5
Works with: .NET version 4.0
Works with: .NET version 4.5

One Line version:

Console::WriteLine("Hello world!")

Hello World Program:

 
//compile using the new dylan.NET v, 11.5.1.2 or later
//use mono to run the compiler
#refstdasm mscorlib.dll
 
import System
 
assembly helloworld exe
ver 1.2.0.0
 
class public Program
 
method public static void main()
Console::WriteLine("Hello world!")
end method
 
end class
 

E[edit]

println("Hello world!")
 
stdout.println("Hello world!")

eC[edit]

class GoodByeApp : Application
{
void Main()
{
PrintLn("Hello world!");
}
}

EchoLisp[edit]

 
(display "Hello world!" "color:blue")
 

ECL[edit]

 
OUTPUT('Hello world!');
 

Efene[edit]

short version (without a function)

io.format("Hello world!~n")

complete version (put this in a file and compile it)

@public 
run = fn () {
io.format("Hello world!~n")
}

Egison[edit]

 
(define $main
(lambda [$argv]
(write-string "Hello world!\n")))
 

EGL[edit]

Works with: EDT
Works with: RBD
 
program HelloWorld
function main()
SysLib.writeStdout("Hello world!");
end
end
 

Eiffel[edit]

This page uses content from Wikipedia. The original article was at Eiffel (programming language). The list of authors can be seen in the page history. As with Rosetta Code, the text of Wikipedia is available under the GNU FDL. (See links for details on variance)
class
HELLO_WORLD
create
make
feature
make
do
print ("Hello world!%N")
end
end

Ela[edit]

open monad io
do putStrLn "Googbye, World!" ::: IO

elastiC[edit]

From the elastiC Manual.

package hello;
 
// Import the `basic' package
import basic;
 
// Define a simple function
function hello()
{
// Print hello world
basic.print( "Hello world!\n" );
}
 
/*
* Here we start to execute package code
*/
 
// Invoke the `hello' function
hello();

Elena[edit]

#symbol Program =
[
system'console writeLine:"Hello world!".
].

Elena Script[edit]

[[
#define start ::= "?" < system'console.eval&writeLine( > $literal < ) >;
]]
 
? "Hello world!"
 

Elisa[edit]

 "Hello world!"? 

Elixir[edit]

 
IO.puts "Hello world!"
 

Elm[edit]

main = plainText "Goodbye World!"

Emacs Lisp[edit]

(insert "Hello world!")

Erlang[edit]

io:format("Hello world!~n").

ERRE[edit]

 
! Hello World in ERRE language
PROGRAM HELLO
BEGIN
PRINT("Hello world!")
END PROGRAM
 

Euler Math Toolbox[edit]

"Hello world!"

Extended BrainF***[edit]

[.>]@Hello world!

Ezhil[edit]

பதிப்பி"வணக்கம் உலகம்!"
பதிப்பி "Hello world!"
பதிப்பி"******* வணக்கம்! மீண்டும் சந்திப்போம் *******"
exit()

F#[edit]

printfn "%s" "Hello world!"

or using .Net classes directly

System.Console.WriteLine("Hello world!")

Factor[edit]

"Hello world!" print

Falcon[edit]

With the printl() function:

printl("Hello world!")

Or via "fast print":

> "Hello world!"

FALSE[edit]

"Hello world!
"

Fantom[edit]

 
class HelloText
{
public static Void main ()
{
echo ("Hello world!")
}
}
 

ferite[edit]

word.}}

uses "console";
Console.println( "Goodby, World!" );

Fexl[edit]

say "Hello world!"

Fish[edit]

Standard Hello, world example, modified for this task:

!v"Hello world!"r!
>l?!;o

Explanation of the code:
!v" jumps over the v character with the ! sign, then starts the string mode with " .
Then the characters Hello world! are added, and string mode is closed with ".
The stack is reversed for printing (r), and a jump (!) is executed to jump over the ! at the beginning of the line and execute the v. (Fish is torical)
After going down by v, it goes rightwards again by > and this line is being executed.
This line pushes the stack size (l), and stops (;) if the top item on the stack is equal to 0 (?). Else it executes the ! directly after it and jumps to the o, which outputs the top item in ASCII. Then the line is executed again. It effectively prints the stack until it's empty, then it terminates.

Forth[edit]

." Hello world!"

Or as a whole program:

: goodbye ( -- )   ." Hello world!" CR ;

Fortran[edit]

Works with: F77

Simplest case - display using default formatting:

print *,"Hello world!"

Use explicit output format:

100   format (5X,A,"!")
print 100,"Hello world!"

Output to channels other than stdout goes like this:

write (89,100) "Hello world!"

uses the format given at label 100 to output to unit 89. If output unit with this number exists yet (no "OPEN" statement or processor-specific external unit setting), a new file will be created and the output sent there. On most UNIX/Linux systems that file will be named "fort.89".

Fortress[edit]

export Executable                                                                                                                       
 
run() = println("Hello world!")

FreeBASIC[edit]

'FreeBASIC Hello-fb0.bas May 2015
'
Screen 0 'open text window
Print "Hello world"
 
Print "Enter any key to go the graphics screen"
sleep
 
screen 18 'Screen 18 Resolution 640x480 with at least 256 colors
locate 10,10
Print "Hello world!"
 
locate 20,10
Print "Enter any key to exit"
sleep
End

Frege[edit]

Works with: Frege version 3.20.113
module HelloWorld where
main _ = println "Hello world!"

friendly interactive shell[edit]

Unlike other UNIX shell languages, fish doesn't support history substitution, so ! is safe to use without quoting.

echo Hello world!

Frink[edit]

 
println["Hello world!"]
 

FunL[edit]

println( 'Hello world!' )

Gambas[edit]

 
PRINT "Hello world!"
 

GAP[edit]

# Several ways to do it
"Hello world!";
 
Print("Hello world!\n"); # No EOL appended
 
Display("Hello world!");
 
f := OutputTextUser();
WriteLine(f, "Hello world!\n");
CloseStream(f);

gecho[edit]

'Hello, <> 'World! print

Gema[edit]

Gema ia a preprocessor that reads an input file and writes an output file. This code will write "Hello world!' no matter what input is given.

*= ! ignore off content of input
\B=Hello world!\! ! Start output with this text.

Gentee[edit]

func hello <main>
{
print("Hello world!")
}

GLBasic[edit]

STDOUT "Hello world!"

Glee[edit]

"Hello world!"

or

'Hello world!'

or to display with double quotes

 '"Goodbye,World!"'

or to display with single quotes

 "'Goodbye,World!'"

GML[edit]

show_message("Hello world!"); // displays a pop-up message
show_debug_message("Hello world!"); // sends text to the debug log or IDE

Go[edit]

package main
 
import "fmt"
 
func main() { fmt.Println("Hello world!") }

Golfscript[edit]

"Hello world!"

Gosu[edit]

print("Hello world!")

Groovy[edit]

println "Hello world!"

GW-BASIC[edit]

10 PRINT "Hello world!"

Hack[edit]

<?hh echo 'Hello world!'; ?>

Harbour[edit]

? "Hello world!"

Haskell[edit]

main = putStrLn "Hello world!"

Haxe[edit]

trace("Hello world!");

HicEst[edit]

WRITE() 'Hello world!'

HLA[edit]

program goodbyeWorld;
#include("stdlib.hhf")
begin goodbyeWorld;
 
stdout.put( "Hello world!" nl );
 
end goodbyeWorld;

Hoon[edit]

~&  "Hello world!"  ~

HQ9+[edit]

This example is incorrect. output isn't consistent with the task's requirements (and is probably incapable of solving the task). Please fix the code and remove this message.
H
  • Technically, HQ9+ can't print "Hello world!" text because of its specification.

- H : Print 'Hello World!'
- Q : Quine
- 9 : Print '99 Bottles of Beer'
- + : Increase Pointer (useless!)

Icon and Unicon[edit]

procedure main()
write( "Hello world!" )
end

IDL[edit]

print,'Hello world!'

Inform 6[edit]

[Main;
print "Hello world!^";
];

Integer BASIC[edit]

NOTE: Integer BASIC was written (and hand-assembled by Woz himself) for the Apple 1 and original Apple 2. The Apple 1 has NO support for lower-case letters, and it was an expensive (and later) option on the Apple 2. This example accurately represents the only reasonable solution for those target devices, and therefore cannot be "fixed", only deleted.

   10 PRINT "Hello world!"
20 END

Io[edit]

"Hello world!" println

Ioke[edit]

"Hello world!" println

IWBASIC[edit]

 
OPENCONSOLE
 
PRINT"Hello world!"
 
'This line could be left out.
PRINT:PRINT:PRINT"Press any key to end."
 
'Keep the console from closing right away so the text can be read.
DO:UNTIL INKEY$<>""
 
CLOSECONSOLE
 
END
 

J[edit]

   'Hello world!'
Hello world!

Here are some redundant alternatives:

   [data=. 'Hello world!'
Hello world!
data
Hello world!
smoutput data
Hello world!

Jack[edit]

class Main {
function void main () {
do Output.printString("Hello world!");
do Output.println();
return;
}
}

Jacquard Loom[edit]

This weaves the string "Hello world!"

+---------------+
| |
| * * |
|* * * * |
|* * *|
|* * *|
|* * * |
| * * * |
| * |
+---------------+
 
+---------------+
| |
|* * * |
|* * * |
| * *|
| * *|
|* * * |
|* * * * |
| * |
+---------------+
 
+---------------+
| |
|* ** * * |
|******* *** * |
| **** * * ***|
| **** * ******|
| ****** ** * |
| * * * * |
| * |
+---------------+
 
+---------------+
| |
|******* *** * |
|******* *** * |
| ** *|
|* * * *|
|******* ** * |
|******* *** * |
| * |
+---------------+
 
+---------------+
| |
|******* *** * |
|******* *** * |
| * * * *|
| * * * *|
|******* ** * |
|******* ** * |
| * |
+---------------+
 
+---------------+
| |
|***** * *** * |
|******* *** * |
| * * * * |
| * * * |
|****** ** * |
|****** ** * |
| * |
+---------------+
 
+---------------+
| |
| * * * |
|***** * ***** |
|***** ** * ***|
|***** ** * ***|
|******* * ** |
| * * * * |
| * |
+---------------+
 
+---------------+
| |
| |
| * * |
| * * |
| * |
| * |
| |
| |
+---------------+

Java[edit]

public class HelloWorld
{
public static void main(String[] args)
{
System.out.println("Hello world!");
}
}

JavaScript[edit]

document.write("Hello world!");
Works with: NJS version 0.2.5
Works with: Rhino
Works with: SpiderMonkey
print('Hello world!');
Works with: JScript
WScript.Echo("Hello world!");
Works with: Node.js
console.log("Hello world!")

JCL[edit]

/*MESSAGE Hello world!

Joy[edit]

"Hello world!" putchars.

jq[edit]

"Hello world!"

Julia[edit]

println("Hello world!")

Kaya[edit]

program hello;
 
Void main() {
// My first program!
putStrLn("Hello world!");
}

Kdf9 Usercode[edit]

This example is incorrect. output isn't consistent with the task's requirements: wording, punctuation. Please fix the code and remove this message.
 
 
V2; W0;
RESTART; J999; J999;
PROGRAM; (main program);
V0 = Q0/AV1/AV2;
V1 = B0750064554545700; ("Hello" in Flexowriter code);
V2 = B0767065762544477; ("World" in Flexowriter code);
V0; =Q9; POAQ9; (write "Hello World" to Flexowriter);
999; OUT;
FINISH;
 

Kite[edit]

simply a single line

"#!/usr/local/bin/kite
 
"Hello world!"|print;

Kitten[edit]

"Hello world!" say

KonsolScript[edit]

Displays it in a text file or console/terminal.

function main() {
Konsol:Log("Hello world!")
}

Kotlin[edit]

fun main(args: Array<String>) {
println("Hello world!")
}

Lang5[edit]

"Hello world!\n" .

LaTeX[edit]

 
\documentclass{scrartcl}
 
\begin{document}
Hello World!
\end{document
}
 


Lasso[edit]

A plain string is output automatically.

'Hello world!'

LFE[edit]

 
(: io format '"Hello world!~n")
 

Liberty BASIC[edit]

print "Hello world!"

Lily[edit]

There are two ways to do this. First, with the builtin print:

print("Hello world!\n")

Second, by using stdout directly:

stdout.write("Hello world!\n")

Limbo[edit]

implement Command;
 
include "sys.m";
sys: Sys;
 
include "draw.m";
 
include "sh.m";
 
init(nil: ref Draw->Context, nil: list of string)
{
sys = load Sys Sys->PATH;
sys->print("Hello world!\n");
}

Lisaac[edit]

Works with: Lisaac version 0.13.1

You can print to standard output in Lisaac by calling STRING.print or INTEGER.print:

Section Header          // The Header section is required.
+ name := GOODBYE; // Define the name of this object.
 
Section Public
- main <- ("Hello world!\n".print;);

However, it may be more straightforward to use IO.print_string instead:

Section Header          // The Header section is required.
+ name := GOODBYE2; // Define the name of this object.
 
Section Public
- main <- (IO.put_string "Hello world!\n";);

LiveCode[edit]

Example on OS X using livecode-server in shell script

#! /usr/local/bin/livecode-server
set the outputLineEndings to "lf"
put "Hello world!" & return
Livecode also supports stdout as a device to write to
write "Hello world!" & return to stdout

LLVM[edit]

@str = internal constant [14 x i8] c"Hello, world!\00"
declare i32 @puts(i8*)
define i32 @main()
{
call i32 @puts( i8* getelementptr ([14 x i8]* @str, i32 0,i32 0))
ret i32 0
}

Lobster[edit]

print "Hello world!"

[edit]

Print includes a line feed:

print [Hello world!]

Type does not:

type [Hello world!]

Logtalk[edit]

:- object(hello_world).
 
% the initialization/1 directive argument is automatically executed
% when the object is loaded into memory:
:- initialization(write('Hello world!\n')).
 
:- end_object.

LOLCODE[edit]

 
HAI
CAN HAS STDIO?
VISIBLE "Hello world!"
KTHXBYE
 

LotusScript[edit]

:- object(hello_world).
'This will send the output to the status bar at the bottom of the Notes client screen
print "Hello world!"
 
:- end_object.

LSE64[edit]

"Hello world!" ,t nl

Lua[edit]

Function calls with either a string literal or a table constructor passed as their only argument do not require parentheses.

print "Hello world!"

Harder way with a table:

 
local chars = {"G","o","o","d","b","y","e",","," ","W","o","r","l","d","!"}
for i = 1, #chars do
write(chars[i])
end
 

M4[edit]

For the particular nature of m4, this is simply:

`Hello world!'

make[edit]

Makefile contents:

 
all:
$(info Hello world!)
 

Running make produces:

Hello world!
make: Nothing to be done for `all'.

Malbolge[edit]

Long Version:

('&%:9]!~}|z2Vxwv-,POqponl$Hjig%eB@@>}=<M:9wv6WsU2T|nm-,jcL(I&%$#"
`CB]V?Tx<uVtT`Rpo3NlF.Jh++FdbCBA@?]!~|4XzyTT43Qsqq(Lnmkj"Fhg${z@>

Short Version:

(=<`#9]~6ZY32Vx/4Rs+0No-&Jk)"Fh}|Bcy?`=*z]Kw%oG4UUS0/@-ejc(:'8dc
Output:
HELLO WORLD!

Maple[edit]

 
> printf( "Hello world!\n" ): # print without quotes
Hello world!
 

Mathematica / Wolfram Language[edit]

Print["Hello world!"]

MATLAB[edit]

>> disp('Hello world!')

Maude[edit]

 
fmod BYE-WORLD is
 
protecting STRING .
 
op sayBye : -> String .
 
eq sayBye = "Hello world!" .
 
endfm
 
red sayBye .
 

Maxima[edit]

print("Hello world!");

MAXScript[edit]

print "Hello world!"

or:

format "%" "Hello world!"

Mercury[edit]

:- module hello.
:- interface.
:- import_module io.
:- pred main(io::di, io::uo) is det.
 
:- implementation.
main(!IO) :-
io.write_string("Hello world!\n", !IO).

Metafont[edit]

message "Hello world!"; end

MIPS Assembly[edit]

Works with: MARS
and
Works with: SPIM
   .data
hello: .asciiz "Hello world!"
 
.text
main:
la $a0, hello
li $v0, 4
syscall
li $v0, 10
syscall

mIRC Scripting Language[edit]

echo -ag Hello world!

ML/I[edit]

Hello world!

Modula-2[edit]

MODULE Hello;
IMPORT InOut;
 
BEGIN
InOut.WriteString('Hello world!');
InOut.WriteLn
END Hello.

Modula-3[edit]

MODULE Goodbye EXPORTS Main;
 
IMPORT IO;
 
BEGIN
IO.Put("Hello world!\n");
END Goodbye.

Morfa[edit]

 
import morfa.io.print;
func main(): void
{
println("Hello world!");
}
 

MUF[edit]

: main[ -- ]
me @ "Hello world!" notify
exit
;

MUMPS[edit]

Write "Hello world!",!

MyrtleScript[edit]

script HelloWorld {
func main returns: int {
print("Hello World!")
}
}
 

MySQL[edit]

SELECT 'Hello world!';

Mythryl[edit]

print "Hello world!";

Neat[edit]

void main() writeln "Hello world!";

Neko[edit]

$print("Hello world!");

Nemerle[edit]

 
class Hello
{
static Main () : void
{
System.Console.WriteLine ("Hello world!");
}
}
 

Easier method:

 
System.Console.WriteLine("Hello world!");
 

NetRexx[edit]

say  'Hello world!'

newLISP[edit]

Works with: newLisp version 6.1 and after
(println "Hello world!")

Nim[edit]

echo("Hello world!")

Nit[edit]

print "Hello world!"

Oberon-2[edit]

 
MODULE Goodbye;
IMPORT Out;
PROCEDURE World*;
BEGIN
Out.String("Hello world!");Out.Ln
END World;
BEGIN
World;
END Goodbye.
 

Objeck[edit]

 
class Hello {
function : Main(args : String[]) ~ Nil {
"Hello world!"->PrintLine();
}
}

Objective-C[edit]

Works with: clang-602.0.53

The de facto Objective-C "Hello, World!" program is most commonly illustrated as the following, using the NSLog() function:

 
#import <Foundation/Foundation.h>
 
int main() {
@autoreleasepool {
NSLog(@"Hello, World!");
}
}
 

However the purpose of the NSLog() function is to print a message to standard error prefixed with a timestamp, which does not meet the most common criteria of a "Hello, World!" program of displaying only the requested message to standard output.

The following code prints the message to standard output without a timestamp using exclusively Objective-C messages:

 
#import <Foundation/Foundation.h>
 
int main() {
@autoreleasepool {
NSFileHandle *standardOutput = [NSFileHandle fileHandleWithStandardOutput];
NSString *message = @"Hello, World!\n";
[standardOutput writeData:[message dataUsingEncoding:NSUTF8StringEncoding]];
}
}
 

Objective-C also supports functions contained within the C standard library. However, Objective-C's NSString objects must be converted into a UTF-8 string in order to be supported by the C language's I/O functions.

 
#import <Foundation/Foundation.h>
 
int main() {
@autoreleasepool {
NSString *message = @"Hello, World!\n";
printf("%s", message.UTF8String);
}
}
 

OCaml[edit]

print_endline "Hello world!"

Occam[edit]

Works with: kroc
#USE "course.lib"
PROC main (CHAN BYTE screen!)
out.string("Hello world!*c*n", 0, screen)
:

Octave[edit]

disp("Hello world!");

Or, using C-style function printf:

printf("Hello world!");

Oforth[edit]

"Hello world!" println

Onyx[edit]

`Hello world!\n' print

OOC[edit]

To print a String, either call its println() method:

main: func {
"Hello world!" println()
}

Or call the free println() function with the String as the argument.

main: func {
println("Hello world!")
}

ooRexx[edit]

Refer also to the Rexx and NetRexx solutions. Simple output is common to most Rexx dialects.

/* Rexx */
say 'Hello world!'
 

Openscad[edit]

 
echo("Hello world!"); // writes to the console
text("Hello world!"); // creates 2D text in the object space
linear_extrude(height=10) text("Hello world!"); // creates 3D text in the object space
 

Oxygene[edit]

From wp:Oxygene (programming language)

 
namespace HelloWorld;
 
interface
 
type
HelloClass = class
public
class method Main;
end;
 
implementation
 
class method HelloClass.Main;
begin
System.Console.WriteLine('Hello world!');
end;
 
end.
 
>HelloWorld.exe
Hello world!

Oz[edit]

{Show "Hello world!"}

PARI/GP[edit]

print("Hello world!")

Pascal[edit]

Works with: Free Pascal
program byeworld;
begin
writeln('Hello world!');
end.

PASM[edit]

print "Hello world!\n"
end

PDP-11 Assembly[edit]

Works with: UNIX version 7

This is tested on Unix v7 Prints "Hello world!" to stdout:

.globl  start
.text
start:
mov $1,r0
sys 4; outtext; outlen
sys 1
rts pc
 
.data
outtext: <Hello world!\n>
outlen = . - outtext

Perl[edit]

Works with: Perl version 5.8.8
print "Hello world!\n";
Works with: Perl version 5.10.x

Backported from Perl 6:

use feature 'say';
say 'Hello world!';

or:

use 5.010;
say 'Hello world!';

Perl 6[edit]

say 'Hello world!';

Phix[edit]

puts(1,"Hello world!")

PHL[edit]

module helloworld;
extern printf;
 
@Integer main [
printf("Hello world!");
return 0;
]

PHP[edit]

<?php
echo "Hello world!\n";
?>

Alternatively, any text outside of the <?php ?> tags will be automatically echoed:

Hello world!

PicoLisp[edit]

(prinl "Hello world!")

Pike[edit]

int main(){
write("Hello world!\n");
}

PIR[edit]

.sub hello_world_text :main
print "Hello world!\n"
.end

PL/I[edit]

goodbye:proc options(main);
put list('Hello world!');
end goodbye;

Pony[edit]

actor Main
new create(env: Env) =>
env.out.print("Hello world!")

Pop11[edit]

printf('Hello world!\n');

PostScript[edit]

The "==" and "=" operators display the topmost element of the stack with or without processing, followed by a newline. Thus:

(Hello world!) ==

will display the string "(Hello world!)" while

(Hello world!) =

will display the content of the string "(Hello world!)"; that is, "Hello world!".

To print a string without the following newline, use

(Hello world!) print

PowerShell[edit]

'Hello world!'
 
#It's considered good practice to use Write-Host, although it works just fine without too
Write-Host 'Hello world!'
 
# For extra flair, you can specify colored output
Write-Host 'Hello world!' -foregroundcolor red

ProDOS[edit]

printline Hello world!

Prolog[edit]

:- write('Hello world!'), nl.

PSQL[edit]

 EXECUTE BLOCK
   RETURNS(S VARCHAR(40))
 AS
 BEGIN
   S = 'Hello world!';
   SUSPEND;
 END

Pure[edit]

 
using system;
 
puts "Hello world!\n" ;
 

PureBasic[edit]

OpenConsole()
PrintN("Hello world!")
Input() ; Wait for enter

Python[edit]

Works with: Python version 2.4
print "Hello world!"

The same using sys.stdout

import sys
sys.stdout.write("Hello world!\n")

In Python 3.0, print is changed from a statement to a function.

Works with: Python version 3.0
(And version 2.X too).
print("Hello world!")

Quill[edit]

"Hello world!" print

R[edit]

 cat("Hello world!\n")

Ra[edit]

 
class HelloWorld
**Prints "Hello world!"**
 
on start
 
print "Hello world!"
 

Racket[edit]

 
(printf "Hello world!\n")
 

Raven[edit]

'Hello world!' print

REALbasic[edit]

Works with: REALbasic version 5.5

This requires a console application.

Function Run(args() as String) As Integer
Print "Hello world!"
Quit
End Function

REBOL[edit]

print "Hello world!"

RED[edit]

print "Hello world!"

Retro[edit]

 
"Hello world!" puts
 

REXX[edit]

using SAY[edit]

/*REXX program to show a line of text.  */
say 'Hello world!'

using SAY variable[edit]

/*REXX program to show a line of text.  */
yyy = 'Hello world!'
say yyy

using LINEOUT[edit]

/*REXX program to show a line of text.  */
 
call lineout ,"Hello world!"

RTL/2[edit]

TITLE Goodbye World;
 
LET NL=10;
 
EXT PROC(REF ARRAY BYTE) TWRT;
 
ENT PROC INT RRJOB();
 
TWRT("Hello world!#NL#");
RETURN(1);
 
ENDPROC;

Ring[edit]

See "Hello world!"

Ruby[edit]

Works with: Ruby version 1.8.4
puts "Hello world!"

or

$stdout.puts "Hello world!"

or even

 STDOUT.write "Hello world!\n"

Run BASIC[edit]

print "Hello world!"

Rust[edit]

 
fn main () {
println!("Hello world!");
}
 

Salmon[edit]

"Hello world!"!

or

print("Hello world!\n");

or

standard_output.print("Hello world!\n");

SAS[edit]

/* Using a data step. Will print the string in the log window */
data _null_;
put "Hello world!";
run;

Sather[edit]

class GOODBYE_WORLD is
main is
#OUT+"Hello world!\n";
end;
end;

Scala[edit]

Library: Console

Ad hoc REPL solution[edit]

Ad hoc solution as REPL script. Type this in a REPL session:

println("Hello world!")

Via Java runtime[edit]

This is a call to the Java run-time library. Not recommendated.

System.out.println("Hello world!")

Via Scala Console API[edit]

This is a call to the Scala run-time library. Recommendated.

println("Hello world!")

Short term deviation to out[edit]

Console.withErr(Console.out) { Console.err.println("This goes to default _out_") }

Long term deviation to out[edit]

  Console.err.println ("Err not deviated")
Console.setErr(Console.out)
Console.err.println ("Err deviated")
Console.setErr(Console.err) // Reset to normal

Scheme[edit]

Works with: Gauche
Works with: Guile
(display "Hello world!")
(newline)
Works with: Gauche
(print "Hello world!")

or just:

"Hello world!"

(should work on any scheme)

R7RS Scheme[edit]

(import (scheme base)
(scheme write))
(display "Hello world!")
(newline)

Scilab[edit]

disp("Hello world!");

sed[edit]

i\
Hello world!
q

Seed7[edit]

$ include "seed7_05.s7i";
 
const proc: main is func
begin
writeln("Hello world!");
end func;

Self[edit]

'Hello world!' printLine.

SETL[edit]

print("Hello world!");

Shen[edit]

(output "Hello world!~%")

Shiny[edit]

say 'Hello world!'

Sidef[edit]

„Hello world!”.say;

SIMPOL[edit]

function main()
end function "Hello world!{d}{a}"

Simula[edit]

Works with: SIMULA-67
BEGIN
OUTTEXT("Hello world!");
OUTIMAGE
END

Sisal[edit]

define main
 
% Sisal doesn't yet have a string built-in.
% Let's define one as an array of characters.
 
type string = array[character];
 
function main(returns string)
"Hello world!"
end function

Slate[edit]

inform: 'Hello world!'.

Smalltalk[edit]

Transcript show: 'Hello world!'; cr.
Works with: GNU Smalltalk
(as does the above code)
'Hello world!' printNl.


SmileBASIC[edit]

PRINT "Hello world!"

SNOBOL4[edit]

Using CSnobol4 dialect

    OUTPUT = "Hello world!"
END

SNUSP[edit]

Core SNUSP[edit]

/++++!/===========?\>++.>+.+++++++..+++\
\+++\ | /+>+++++++>/ /++++++++++<<.++>./
$+++/ | \+++++++++>\ \+++++.>.+++.-----\
\==-<<<<+>+++/ /=.>.+>.--------.-/

Modular SNUSP[edit]

@\G.@\o.o.@\d.--b.@\y.@\e.>@\comma.@\.<-@\W.+@\o.+++r.------l.@\d.>+.! #
| | \@------|# | \@@+@@++|+++#- \\ -
| \@@@@=+++++# | \===--------!\===!\-----|-------#-------/
\@@+@@@+++++# \!#+++++++++++++++++++++++#!/

SoneKing Assembly[edit]

 
extern print
 
dv Msg Goodbye,World!
 
mov eax Msg
push
call print
pop
 

SPARC Assembly[edit]

 
.section ".text"
.global _start
_start:
mov 4,%g1 ! 4 is SYS_write
mov 1,%o0 ! 1 is stdout
set .msg,%o1 ! pointer to buffer
mov (.msgend-.msg),%o2 ! length
ta 8
 
mov 1,%g1 ! 1 is SYS_exit
clr %o0 ! return status is 0
ta 8
 
.msg:
.ascii "Hello world!\n"
.msgend:
 

Sparkling[edit]

print("Hello world!");

Standard ML[edit]

print "Hello world!\n"

Suneido[edit]

Print("Hello world!")

Swift[edit]

Works with: Swift version 2.x+
print("Hello world!")
Works with: Swift version 1.x
println("Hello world!")

Symsyn[edit]

 
'hello world' []
 

Tcl[edit]

Output to terminal:

puts "Hello world!"

Output to arbitrary open, writable file:

puts $fileID "Hello world!"

Teco[edit]

Outputting to terminal. Please note that ^A means control-A, not a caret followed by 'A', and that $ represent the ESC key.

^AHello world!^A$$

Terra[edit]

C = terralib.includec("stdio.h")
 
terra hello(argc : int, argv : &rawstring)
C.printf("Hello world!\n")
return 0
end

TestML[edit]

%TestML 0.1.0
Print("Hello world!")

TI-83 BASIC[edit]

Disp "Hello world!

(Lowercase letters DO exist in TI-BASIC, though you need an assembly program to enable them.)

TI-89 BASIC[edit]

Disp "Hello world!"

TorqueScript[edit]

echo("Hello world!");

TPP[edit]

Hello world!

Transact-SQL[edit]

PRINT "Hello world!"

Trith[edit]

"Hello world!" print

TUSCRIPT[edit]

 
$$ MODE TUSCRIPT
PRINT "Hello world!"
 

Output:

Hello world!

Uniface[edit]

 
message "Hello world!"
 

UNIX Shell[edit]

Works with: Bourne Shell
#!/bin/sh
echo "Hello world!"

C Shell[edit]

#!/bin/csh -f
echo "Hello world!\!"

We use \! to prevent history substitution. Plain ! at end of string seems to be safe, but we use \! to be sure.

Unlambda[edit]

`r```````````````.G.o.o.d.b.y.e.,. .W.o.r.l.d.!i

Ursala[edit]

output as a side effect of compilation

#show+
 
main = -[Hello world!]-

output by a compiled executable

#import std
 
#executable ('parameterized','')
 
main = <file[contents: -[Hello world!]-]>!

உயிர்/Uyir[edit]

முதன்மை என்பதின் வகை எண் பணி {{
("உலகத்தோருக்கு வணக்கம்") என்பதை திரை.இடு;
 
முதன்மை = 0;
}};

V[edit]

"Hello world!" puts

Vala[edit]

void main(){
stdout.printf("Hello world!\n");
}

VBScript[edit]

Works with: Windows Script Host version 5.7
WScript.Echo("Hello world!")

Vedit macro language[edit]

Message("Hello world!")

VHDL[edit]

LIBRARY std;
USE std.TEXTIO.all;
 
entity test is
end entity test;
 
architecture beh of test is
begin
process
variable line_out : line;
begin
write(line_out, string'("Hello world!"));
writeline(OUTPUT, line_out);
wait; -- needed to stop the execution
end process;
end architecture beh;

Vim Script[edit]

echo "Hello world!\n"

Wart[edit]

prn "Hello world!"

Whenever[edit]

1 print("Hello world!");

Whiley[edit]

import whiley.lang.System
 
method main(System.Console console):
console.out.println("Hello world!")

Whitespace[edit]

There is a "Hello World" - example-program on the Whitespace-website

Wolfram Language[edit]

Print["Hello world!"]

Wren[edit]

IO.print("Hello world!")

X86 Assembly[edit]

Works with: nasm version 2.05.01

This is known to work on Linux, it may or may not work on other Unix-like systems

Prints "Hello world!" to stdout (and there is probably an even simpler version):

section .data
msg db 'Hello world!', 0AH
len equ $-msg
 
section .text
global _start
_start: mov edx, len
mov ecx, msg
mov ebx, 1
mov eax, 4
int 80h
 
mov ebx, 0
mov eax, 1
int 80h

AT&T syntax: works with gcc (version 4.9.2) and gas (version 2.5):

.section .text
 
.globl main
 
main:
movl $4,%eax #syscall number 4
movl $1,%ebx #number 1 for stdout
movl $str,%ecx #string pointer
movl $16,%edx #number of bytes
int $0x80 #syscall interrupt
ret
 
.section .data
str: .ascii "Hello world!\12"

AT&T syntax (x64):

// No "main" used
// compile with `gcc -nostdlib`
#define SYS_WRITE $1
#define STDOUT $1
#define SYS_EXIT $60
#define MSGLEN $14
 
.global _start
.text
 
_start:
movq $message, %rsi // char *
movq SYS_WRITE, %rax
movq STDOUT, %rdi
movq MSGLEN, %rdx
syscall // sys_write(message, stdout, 0x14);
 
movq SYS_EXIT, %rax
xorq  %rdi, %rdi // The exit code.
syscall // exit(0)
 
.data
message: .ascii "Hello, world!\n"

xEec[edit]

 
h#10 h$! h$d h$l h$r h$o h$w h#32
h$o h$l h$l h$e h$H >o o$ p jno
 

XL[edit]

use XL.UI.CONSOLE
WriteLn "Hello world!"

XPL0[edit]

code Text=12;
Text(0, "Hello world!
")

XSLT[edit]

<xsl:text>Hello world!
</xsl:text>

Yorick[edit]

write, "Hello world!"

Z80 Assembly[edit]

Using the Amstrad CPC firmware:

org		$4000
 
txt_output: equ $bb5a
 
push hl
ld hl,world
 
print: ld a,(hl)
cp 0
jr z,end
call txt_output
inc hl
jr print
 
end: pop hl
ret
 
world: defm "Hello world!\r\n\0"

zkl[edit]

println("Hello world!");