# “Hello, World!”

So... uh... this is a bit embarrassing. But we don't have a plain "Hello, World!" challenge yet (despite having 35 variants tagged with , and counting). While this is not the most interesting code golf in the common languages, finding the shortest solution in certain esolangs can be a serious challenge. For instance, to my knowledge it is not known whether the shortest possible Brainfuck solution has been found yet.

Furthermore, while all of Wikipedia (the Wikipedia entry has been deleted but there is a copy at archive.org ), esolangs and Rosetta Code have lists of "Hello, World!" programs, none of these are interested in having the shortest for each language (there is also this GitHub repository). If we want to be a significant site in the code golf community, I think we should try and create the ultimate catalogue of shortest "Hello, World!" programs (similar to how our basic quine challenge contains some of the shortest known quines in various languages). So let's do this!

## The Rules

• Each submission must be a full program.
• The program must take no input, and print Hello, World! to STDOUT (this exact byte stream, including capitalization and punctuation) plus an optional trailing newline, and nothing else.
• The program must not write anything to STDERR.
• If anyone wants to abuse this by creating a language where the empty program prints Hello, World!, then congrats, they just paved the way for a very boring answer.

Note that there must be an interpreter so the submission can be tested. It is allowed (and even encouraged) to write this interpreter yourself for a previously unimplemented language.

• Submissions are scored in bytes, in an appropriate (pre-existing) encoding, usually (but not necessarily) UTF-8. Some languages, like Folders, are a bit tricky to score - if in doubt, please ask on Meta.
• This is not about finding the language with the shortest "Hello, World!" program. This is about finding the shortest "Hello, World!" program in every language. Therefore, I will not mark any answer as "accepted".
• If your language of choice is a trivial variant of another (potentially more popular) language which already has an answer (think BASIC or SQL dialects, Unix shells or trivial Brainfuck-derivatives like Alphuck), consider adding a note to the existing answer that the same or a very similar solution is also the shortest in the other language.

As a side note, please don't downvote boring (but valid) answers in languages where there is not much to golf - these are still useful to this question as it tries to compile a catalogue as complete as possible. However, do primarily upvote answers in languages where the authors actually had to put effort into golfing the code.

For inspiration, check the Hello World Collection.

## The Catalogue

The Stack Snippet at the bottom of this post generates the catalogue from the answers a) as a list of shortest solution per language and b) as an overall leaderboard.

## Language Name, N bytes


where N is the size of your submission. If you improve your score, you can keep old scores in the headline, by striking them through. For instance:

## Ruby, <s>104</s> <s>101</s> 96 bytes


If there you want to include multiple numbers in your header (e.g. because your score is the sum of two files or you want to list interpreter flag penalties separately), make sure that the actual score is the last number in the header:

## Perl, 43 + 2 (-p flag) = 45 bytes


You can also make the language name a link which will then show up in the snippet:

## [><>](https://esolangs.org/wiki/Fish), 121 bytes


/* Configuration */

var QUESTION_ID = 55422; // Obtain this from the url
// It will be like https://XYZ.stackexchange.com/questions/QUESTION_ID/... on any question page
var COMMENT_FILTER = "!)Q2B_A2kjfAiU78X(md6BoYk";
var OVERRIDE_USER = 8478; // This should be the user ID of the challenge author.

/* App */

return "https://api.stackexchange.com/2.2/questions/" +  QUESTION_ID + "/answers?page=" + index + "&pagesize=100&order=desc&sort=creation&site=codegolf&filter=" + ANSWER_FILTER;
}

}

jQuery.ajax({
method: "get",
dataType: "jsonp",
crossDomain: true,
success: function (data) {
data.items.forEach(function(a) {
});
comment_page = 1;
}
});
}

jQuery.ajax({
method: "get",
dataType: "jsonp",
crossDomain: true,
success: function (data) {
data.items.forEach(function(c) {
if (c.owner.user_id === OVERRIDE_USER)
});
else process();
}
});
}

var SCORE_REG = /<h\d>\s*([^\n,<]*(?:<(?:[^\n>]*>[^\n<]*<\/[^\n>]*>)[^\n,<]*)*),.*?(\d+)(?=[^\n\d<>]*(?:<(?:s>[^\n<>]*<\/s>|[^\n<>]+>)[^\n\d<>]*)*<\/h\d>)/;

function getAuthorName(a) {
return a.owner.display_name;
}

function process() {
var valid = [];

var body = a.body;
if(OVERRIDE_REG.test(c.body))
body = '<h1>' + c.body.replace(OVERRIDE_REG, '') + '</h1>';
});

var match = body.match(SCORE_REG);
if (match)
valid.push({
user: getAuthorName(a),
size: +match[2],
language: match[1],
});
else console.log(body);
});

valid.sort(function (a, b) {
var aB = a.size,
bB = b.size;
return aB - bB
});

var languages = {};
var place = 1;
var lastSize = null;
var lastPlace = 1;
valid.forEach(function (a) {
if (a.size != lastSize)
lastPlace = place;
lastSize = a.size;
++place;

.replace("{{NAME}}", a.user)
.replace("{{LANGUAGE}}", a.language)
.replace("{{SIZE}}", a.size)

var lang = a.language;
lang = jQuery('<a>'+lang+'</a>').text();

languages[lang] = languages[lang] || {lang: a.language, lang_raw: lang, user: a.user, size: a.size, link: a.link};
});

var langs = [];
for (var lang in languages)
if (languages.hasOwnProperty(lang))
langs.push(languages[lang]);

langs.sort(function (a, b) {
if (a.lang_raw.toLowerCase() > b.lang_raw.toLowerCase()) return 1;
if (a.lang_raw.toLowerCase() < b.lang_raw.toLowerCase()) return -1;
return 0;
});

for (var i = 0; i < langs.length; ++i)
{
var language = jQuery("#language-template").html();
var lang = langs[i];
language = language.replace("{{LANGUAGE}}", lang.lang)
.replace("{{NAME}}", lang.user)
.replace("{{SIZE}}", lang.size)
language = jQuery(language);
jQuery("#languages").append(language);
}

}
body {
text-align: left !important;
display: block !important;
}

width: 290px;
float: left;
}

#language-list {
width: 500px;
float: left;
}

font-weight: bold;
}

table td {
}
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<div id="language-list">
<h2>Shortest Solution by Language</h2>
<table class="language-list">
<tr><td>Language</td><td>User</td><td>Score</td></tr>
<tbody id="languages">

</tbody>
</table>
</div>
<tr><td></td><td>Author</td><td>Language</td><td>Size</td></tr>

</tbody>
</table>
</div>
<table style="display: none">
</tbody>
</table>
<table style="display: none">
<tbody id="language-template">
</tbody>
</table>

• Must the language meet our usual requirements for what a programming language is, or are we operating by kolmogorov complexity rules? – isaacg Aug 28 '15 at 13:54
• @isaacg No it doesn't. I think there would be some interesting languages where it's not obvious whether primality testing is possible. – Martin Ender Aug 28 '15 at 13:56
• If the same program, such as "Hello, World!", is the shortest in many different and unrelated languages, should it be posted separately? – aditsu Aug 28 '15 at 15:33
• @mbomb007 Well it's hidden by default because the three code blocks take up a lot of space. I could minify them so that they are a single line each, but I'd rather keep the code maintainable in case bugs come up. – Martin Ender Aug 28 '15 at 19:34
• @ETHproductions "Unlike our usual rules, feel free to use a language (or language version) even if it's newer than this challenge." Publishing the language and an implementation before posting it would definitely be helpful though. – Martin Ender Aug 29 '15 at 23:01

# Cubically, 12412311199 78 bytes

-11 bytes thanks to TehPers, -12 thanks to language updates, -21 thanks to user202729

RU+432@6+50-4@6+3-4@6@6+1-00@6-331@6-00@6+4110@6+0000@6+1-00@6-0@6-2+4@6-331@6


Generated via this amazing algorithm.

There is a good explanation of Cubically in this question.

Cubically, the Rubik's Cube Programming Language, is the most complex language I have ever written, or dealt with, for that matter. It entirely comprises of operations on a single 3x3 Rubik's Cube in its memory, and one extra value, the "notepad".

The only way to perform mathematical operations is to take values from a certain cube face and add/subtract/multiply/divide it with the scratch pad value, replacing said value.

For example, performing /0 divides the notepad value by the sum of all integers on the 0-indexed face, or the first face.

The cube starts out initialized like this:

   000
000
000
111222333444
111222333444
111222333444
555
555
555


Performing a 90-degree clockwise turn on the right face will make the cube look like this:

   002
002
002
111225333044
111225333044
111225333044
554
554
554


Version from TehPers:

Here's a run-down of how the program works: (Note that I have replaced @6 with @ in the code, but changing each instance in the rest of this answer would be too tedious and I need to get back to real life.)

• +53 adds the DOWN face and RIGHT faces into the notepad, in this case, 45 and then 27. This results in 72, the ASCII code for H.
• @6 prints the notepad value as ASCII.
• :2 sets the notepad to the value of the FRONT face (18).
• /1 divides the notepad by the LEFT face (9), resulting in 2.
• +551 Adds the DOWN face (45) twice, then the LEFT face (9). As you can see, without rotating the cube, the faces will contain a total value equal to 9 times the index. For example, face index 5 has a value of 45, face index 1 has a value of 9, and so forth. After rotating the cube, this no longer applies.
• @6 again prints the notepad value, or e.
• :5 sets the notepad to the value of the DOWN face (45).
• +52 adds the DOWN face (45) and the FRONT face (18) to the notepad.
• @66 prints the current notepad value as a character twice. At this point Hell has been printed, which should be good enough for this language. :P
• :3/1 sets the notepad to the value of the RIGHT face (27), then divides the notepad by the value of the LEFT face (9), resulting in 3. Do you see the pattern yet?
• +552 adds 108 to the notepad, or 9*(5+5+2). Remember, if you rotate the cube, then the faces will not necessarily be multiples of 9!
• @6 prints the notepad value as a character, finishing the word "Hello".
• From this point there is nothing interesting. The program follows the pattern of setting the notepad value to whatever c % 9 is (where c is the target character), then adding multiples of 9 to the notepad get to the target character. The faces are not rotated, so this isn't exactly the best showcase program for Cubically, but it's certainly simpler than what could be accomplished with rotating the faces. There may be a shorter way to write this program using rotations, though.

Original (written by hand >.<)

+53@6+1F2L2+0@6L2F2U3R3F1L1+2@66L3F3R1U1B3+0@6:4U1R1+00@6-000@6+50000@6+000000@6+2-000000@6-5+4000@6-00@6/0+00@6:0+0/0+00@6


The above Hello World program uses arbitrary turns that I fiddled with until they got some desired values. Eventually, I got the top face to add up to 4 and made do with that.

Here's a run-down of how the program works:

• +5+3 adds the DOWN face and RIGHT faces into the notepad, in this case, 45 and then 27. This results in 72, the ASCII code for H.
• @6 prints the notepad value as ASCII.
• +1 adds the LEFT face to the notepad value, resulting in 81.
• F2 turns the FRONT face to look like this.
• L2 turns the LEFT face to look like this.
• +0 adds the UP face to the notepad, resulting in 101.
• @6 prints memory as ASCII e.
• L2F2U3R3F1L1 turns the cube to look like this.
• +2 adds the FRONT face to the notepad, resulting in 108. @66 prints as ASCII twice ll. At this point Hell has been printed, which should be good enough for this language. :P
• L3F3R1U1B3 turns the cube to look like this.
• +0 adds the UP face to the notepad (resulting in 111), @6 prints it as ASCII o.
• :4 sets the notepad to the BACK face 36.
• U1R1 turns the cube to look like this. The cube is not turned again 'cause this was about as good of a setup I could get.
• +0+0 adds the UP face to the notepad twice, resulting in 44.
• @6 prints as ASCII ,.
• -000 subtracts 12 from the notepad (32). @6 prints as ASCII .
• From this point there is nothing interesting except messing with the existing faces, particularly the top face (which has a convenient value 4), to print the remaining characters.
• It's not complex, just insanely difficult :o – HyperNeutrino Jun 15 '17 at 0:45
• @HyperNeutrino It's rather complex. Wait for the explanation :P – MD XF Jun 15 '17 at 0:46
• you should change the title on this – Destructible Lemon Jun 15 '17 at 1:32
• Also that is not postfix – Destructible Lemon Jun 15 '17 at 1:32
• @DestructibleLemon oh duh – MD XF Jun 15 '17 at 1:38

# Mind, 26 bytes

The program is encoded in Shift_JIS:

ﾒｲﾝは
"Hello, World!"



It means something like:

MAIN is:
"Hello, World!"
display


As you can see, Mind is a Japanese programming language. It's based on Forth, which turns out to suit Japanese's SOV word order rather well!

# Lua , 22 20 bytes

print"Hello, World!"


Try it online!

Thanks to @mathmandan for saving 2 bytes

• I don't think you need the parentheses, so you can save two bytes: repl.it/BEPR – mathmandan Aug 28 '15 at 15:22
• How about ="Hello, World!" – because technically this does output "Hello, World!". – ascx Sep 7 '15 at 16:26
• @Socialz I just relized(thanks to you) that the = is not even necessary. – jakebacker44 Sep 7 '15 at 16:29
• @JakeBacker I can't reproduce that though, heh, which version are you running? – ascx Sep 7 '15 at 16:30
• @Socialz repl.it/BGIS – jakebacker44 Sep 7 '15 at 16:31

# Pepe, 122 120 bytes

Pepe is my brand new programming language, which is horrible.

reeEeeEeeereeEEeeEeErEeEEeEEeereeereeeREeEEeEEEEReeereeeEeEEeereeeEeeeeereeEeEeEEEReeereeEEEeeEereeereeEEeeEeereeeEeeeeE


Try it online!

There might be shorter solutions, but that's not task for my brain .-.

That's why I'd offer a 50 100 bounty to anyone who can make it shorter, if it's possible. I don't really believe it is, but maybe you can change my mind?

This solution is quite simple, but better to explain it ungolfed and commented:

reeEeeEeee   # H > print H
reeEEeeEeE   # e > print e
rEeEEeEEee   # l > push l to r
reee reee    #     print it twice
REeEEeEEEE   # o > push o to R
Reee         #     print it
reeeEeEEee   # , > print ,
reeeEeeeee   #   > print a space
reeEeEeEEE   # W > print W
Reee         # o > print active value in R (o)
reeEEEeeEe   # r > print r
reee         # l > print active value in r (l)
reeEEeeEee   # d > print d
reeeEeeeeE   # ! > print !


The first line prints Hello, and a space, the second prints World!. Most of this program are character functions, ex. reeEeeEeee which prints H. By letter:

• r - Stack r
• e - Print
• eEeeEeee - 01001000 (72), the ASCII character for H

As said, most of the program consists of similar commands, but, to golf it a bit, in first occurrence of l, I replaced the first e with E, so instead of printing, it pushed the charcode to the stack. Thanks to this, we can later print l using reee, the command for printing. Edit: Now, I've done the same with o, thanks to the existence of the second stack (notice the R letter).

# Self-modifying Brainfuck, 28 19 bytes

␀ represents a literal NUL byte.

<[.<]␀!dlroW ,olleH


Try it online

This is my Python interpreter that is referenced on the Esolangs page for SMBF. The default/example program is the program above. The SMBF code is entered on line 178 so that the Input box can be used for STDIN.

If input is not empty, it would need to be this (20 bytes):

<[.+<]␀!dlroW ,olleH


Since SMBF has its own source code on the same tape, we put the string on the tape in reverse to facilitate printing. Then we print all the cells from right to left up to the cell with zero in it (the cell represented by ␀). After printing, I have to change the comma to a different character so it doesn't look for input. Using + changes it to a - and vice versa, so either way it's a no-op (not that it matters, since printing is done anyway).

• The second version could be just <[.+<]\x00!dlroW ,olleH, couldn't it? – primo Jul 27 '16 at 12:55
• @primo Yeah, it could. – mbomb007 Jul 28 '16 at 14:16
• Doesn't the second version work even with input? Sure, it'll read a byte of input, but the program does the same thing regardless of whether any byte or EOF is read. – user62131 May 1 '17 at 1:13
• Taking input when you're not supposed to isn't allowed. That's what the 2nd program is assuming. – mbomb007 May 1 '17 at 14:29

# Backhand, 15 bytes

"ol!,ld elWHro"


Now on Try It Online thanks to Dennis!

Backhand is my first new language, taking inspiration from 2D languages like Befunge and ><>. However, it is 1D, but makes up for the missing dimension by having the pointer move more than one character at a time. Initially, the program starts at location 0 with step count 3.

"  !  d  l  r       " starts a string literal and starts pushing characters to the stack
o  ,     W  o      Change direction and go left when you reach the end
l  l  e  H  "     Switch direction again to go right and end the string literal
H        Halt and output stack


Of course, it looks quite funny, since the program is also an anagram of just "Hello, World!".

# Forth, 17 bytes

.( Hello, World!)

• ." Hello World! is one byte shorter. – Lynn Aug 28 '15 at 20:27
• ." may only be used within a function declaration. ." : error(-14): use only during compilation – mbomb007 Aug 28 '15 at 20:47
• Why the space in .( Hello,? – Erik the Outgolfer Jun 16 '16 at 14:56
• @EʀɪᴋᴛʜᴇGᴏʟғᴇʀ Forth requires spaces between tokens. The ending ) is the exception to the rule. – mbomb007 Jun 16 '16 at 14:56
• @mbomb007 It's unfair that ." is only in functions. – Erik the Outgolfer Jun 16 '16 at 15:03

# Batch File, 19 Bytes

@echo Hello, World!


Short and to the point. You'd think you could golf off the @ at the beginning, but if you do you get the literal program echo'd out before the string is printed. This is why you'll see @echo off at the beginning of near every .bat file around.

Example without the @

C:\Tools\Scripts>.\hello-world.bat

C:\Tools\Scripts>echo Hello, World!
Hello, World!

• Isn't the language itself just called "Batch"? – mbomb007 Aug 28 '15 at 13:54
• @mbomb007 Kinda, sorta, maybe, not really. Batch files are just collections of lines that are executed by the associated command-line interpreter (usually COMMAND.COM but not necessarily, especially in newer Windows releases). It technically has some additional commands, like the infamous GOTO, but it's not in and of itself a language. – AdmBorkBork Aug 28 '15 at 14:11
• If you leave off the the echo you get an infinite amount of hello world!'s – User112638726 Aug 28 '15 at 14:21
• @User112638726 No, you should get something like 'Hello' is not recognized as an internal or external command, operable program or batch file. If you get something else, you must be using a different version of the interpreter than I am. – AdmBorkBork Aug 28 '15 at 14:28
• @MrPaulch if the filename is significant it has to be added to the byte coutn – undergroundmonorail Aug 30 '15 at 23:01

# J, 15 bytes

'Hello, World!'


No call to any write function needed.

# Bash, 18 bytes

echo Hello, World!


This works when invoked as a full program or with history expansion disabled (default for scripts).

# Pascal, 32 bytes

begin write('Hello, World!')end.


# Julia, 22 bytes

print("Hello, World!")


Short and sweet.

# D, 51 bytes

import std.stdio;void main(){puts="Hello, World!";}


In D, a=b is sometimes equivalent to a(b), allowing us to shave off one more byte than you might expect.

# Unlambda, 36 bytes

.!.d.l.r.W. .,.lc.H.e.oi


Unlambda is a minimal functional programming language based on combinatory logic. It uses prefix notation; fx is an application of f to x. Specifically, .c is a primitive that takes some v, prints the character c as a side-effect, and returns v. Thus, the usual program would be to take i, apply .H to it, apply .e to it, etc., giving you .!.d.l...

This 36-byte solution is due to irori on anarchy golf. It uses the primitive c, which I think is kind of like call/cc, to avoid having to write .o and .l twice. I have no idea how it precisely works. The sort-of equivalent Lisp syntax would be:

(print-!
(print-d
(print-l
(print-r
((print-W
(print-space
(print-comma
((print-l
(call-cc (print-h print-e)))
print-o))))
id)))))


w


Hooray for built-ins.

# PowerShell, 15 Bytes

Likely in Foo (among others) as well, but I'll let someone with more knowledge of those languages post.

"Hello, World!"


or, alternatively,

'Hello, World!'


In PowerShell, both ' and " denote string literals. The difference is the double-quotes will expand variables (e.g., \$myString) and escape characters (e.g., n), while the single-quote will treat everything literally.

PowerShell does an implicit Write of anything that's on a line by itself in a program (the relative merits of Write-Host vs Write-Output are left as an exercise to the reader) -- variable, literal string (as this is), result of a one-line command, etc. This stems from the fact that every line gets executed, and the way to execute a string is to print it. For other data types, if they have a way to convert to a string, the execution silently does the conversion in the background and then prints the resultant string. If there's no way to get a string, you'll wind up printing a description of the datatype. This is one of the ways that PowerShell, as ... verbose clear ... as it is, can wind up somewhat competing with other languages.

A short article on the topic, not written by me, though the author and I have a similar name.

# Prolog, 23 bytes

write('Hello, World!').

• What did you use to define a string if you didn't use "? – Beta Decay Aug 28 '15 at 12:57
• @BetaDecay Nothing, strings didn't exist as far as I know. So using " to create strings would create an array of character codes (ie ascii/unicode codes) representing the string. Character codes strings is created with backquotes in SWI-Prolog now. – Fatalize Aug 28 '15 at 13:01
• You can use single quotes to turn this into an atom, and thus make the program completely portable: write('Hello, World!'). More declaratively, I would simply define a a fact like: msg('Hello, World!').. Usage example: ?- msg(M)., succeeding with M = 'Hello, World!'.. – mat Sep 1 '15 at 12:18
• @mat Good suggestion that I use atoms instead of strings. For the msg('Hello, World!') though, I don't think it's valid in this challenge because it outputs M = 'Hello, World!'. instead of just Hello, World! (granted, it also outputs true after in my answer but I assume this is acceptable because Prolog really likes to output true or false :)) – Fatalize Sep 1 '15 at 12:25
• I know, the way this challenge is formulated kind of forces you to use impure langauge elements. Too bad! (BTW: The last sentence of your post is no longer applicable.) – mat Sep 1 '15 at 12:27

# goruby, 6 bytes

h:H,:W


Apart from the method_missing override, goruby also defines Kernel#h which accepts 3 parameters: the first letter of _ello (default H), the first letter of _orld (default w), and the final character (default !).

• Nice, I didn't know about the parameters it takes :) – Lynn Sep 3 '15 at 2:00

# NULL, 91 bytes

int("8bxyd2qvpj6uq6gh9u8hlrjfwqkx8i2pvid5auhrsrbpp8gsczv6ye26ew0pkx05wem94m9zqkn8prqir",36)


This number represents a program, and it has 126 digits in decimal representation. I use base-36 here to shorten the number. It seems acceptable because the interpreter of NULL uses the python eval on the program before executing it (presumably to allow specifying the program as a product of prime numbers). The prime factorization (used while executing the program) is

3*3*3*17*31*73*127*139*151*157*167*197*239*241*307*367*367*419*479*499*
547*599*619*677*751*839*919*947*947*1019*1039*1097*1129*1217*1249*1301*
1303*1327*1433*1499*1543*1613*1709*1777*1873*1951*1993*2063


I found this program by using something like A* search. It tracks the state of the NULL interpreter and two additional values:

• print - number of characters in the Hello, World! message it managed to output so far
• length - natural logarithm of the number that represents the program

For each state, it picks 10 possible commands the language has (there are 14, but the rest are too uncomfortable to search), and calculates 10 new states. To find the shortest program, it holds the states in a priority_queue, arranged by the following cost function:

print - length / 25


If I use a fudge factor much different from 25, it either keeps searching forever (until it eats all RAM) or finds sub-optimal solutions.

BTW there is a bug in the interpreter in the generation of prime numbers. I fixed it by simplifying the code this way:

def factor_g(include_builtin_list = True):
if include_builtin_list:
for x in plist: yield x
k = plist[-1] + 2
while True:
yield k
k += 2


# Turing Machine Code, 132 bytes

As usual, I'm using the table syntax defined here.

0 * H r q
q * e r w
w * l r e
e * l r r
r * o r t
t * , r y
y * _ r u
u * W r i
i * o r o
o * r r p
p * l r a
a * d r s
s * ! r halt


If the above link isn't working (sometimes it works for me, other times the page refuses to load) you may also test this using this java implementation.

# Candy, 18 bytes + 1 = 19 bytes

Push (technically queue) string (character-by-character) onto the stack, and loop to print

"Hello, World!"(;)


The interpreter should be called with -q to suppress STDOUT messages.

• Why 3 bytes for switch? The Binary-encoded Golfical answer takes a switch and that's only a byte... – cat Dec 14 '15 at 14:23
• There was a suggestion on one of my other posts that suppressing STDOUT should have a cost, so I followed that here. But it doesn't seem to be consistently followed. – Dale Johnson Dec 14 '15 at 22:44
• The convention is typically 1 byte / switch. However, you can raise the question on Meta and get the community's opinion. – cat Dec 14 '15 at 22:56

# Rotor, 14 bytes

"Hello, World!


Nothing too fancy here. Like Pyth, quotes and most other structures are implicitly closed at EOF.

Try it online.

Check out Rotor.

# HolyC, 24 bytes

Print("Hello, World!");


Nothing special here, I just wanted to pay tribute to the lunatic who wrote TempleOS and its companion language, HolyC.

# V, 14 bytes

iHello, World!


Try it online! This enters insert mode, then inserts Hello, World! into the field.

# K (oK), 20 19 bytes

!0:"Hello, World!"


Try it online!

Note that this program gets killed, which effectively prevents implicit or error output. Your shell might indicate that the program was killed, but this output is produced by the shell, not the program.

### Alternative solution, 20 bytes, clean exit

{}0:"Hello, World!"


I'm still trying to figure out why this works, but it does.

Try it online!

### Almost-solutions

• "Hello, World!" prints the string with the quotes.

• 0:"Hello, World!" prints Hello, World!"Hello, World!", the first copy explicitly, then second one implicitly.

• 00:"Hello, World!" prints the correct output to STDOUT, but the leftmost 0 is a type error and prints an error message to STDERR.

• !0:"Hello, World!" prints on

• You know you've attained master rank when you don't know why your code golf works, but it still does. – AdmBorkBork Feb 9 '17 at 20:20
• Of course. The true&tested method of "Can't possibly work, let's try it anyway." ~ Eugene van der Pijll – primo Feb 10 '17 at 11:16

# Wise, 135 + 3 = 138 bytes

~-<<<~-<<<::^~-<~-<<<~-<<~-:::^~-<<<~-^::?:>~-<~-:?::^~-<<~-<~-<<::^~-<<<<<:<::^<~-<<~-<~-<~-|!::^~-<~-<~-<<<~-<!:::^~-<<<^::^~-<<<<<~-


Try it online!

## Alice, 19 18 bytes

Thanks to Sp3000 for saving 1 byte.

"&O@!dlroW ,olleH


There should be a carriage return (0x0D) at the end of the program, but browsers don't like those. Consequently, this version is also not testable on TIO. Here is a 19-byte printable-only alternative:

"!dlroW ,olleH"d&O@


Try it online!

Finally introducing my latest language! This works like Hello, World in most Fungeoids, and doesn't really touch upon all the advanced features Alice has:

"&O@!dlroW ,olleH  Push the individual code points of the entire source code
except the " to the stack. Remember that there's a 13 at the end.
&                  Repeat the next command 13 times.
O                  Pop 13 characters from the stack and print them.
@                  Terminate the program.


In the 19-byte version, we're pushing the 13 explicitly, using the stack depth command d.

Here is a somewhat more interested 21-byte version, which makes use of Alice's main feature: by moving diagonally, Alice operates in a separate mode (called Ordinal mode), which works with strings instead of integers. However, due to the diagonal movement, it's a bit harder to follow the code:

/oH!lloo /
@""edlr,W\


Try it online!

The initial / sends the instruction pointer off southeast, where it will bounce diagonally up and down between the two lines. The \/ at the end offset the IP's position by one cell so that on the way back, the IP bounces through the other characters. So ignoring those mirrors, the code that actually gets executed is:

"Hello, World!"o@


In Ordinal mode, "Hello, World!" actually pushes an entire string to the stack, o prints that string, and then @ still terminates the program.

# Aceto, 19 bytes

Aceto is the coolest programming language because I got it as a birthday present. It is a stack based programming language that makes use of a 2D Hilbert curve grid. Here is Hello World:

o,or
l Wl
le!d
"H"p

• Golfed 16+1=17 for -l flag – drham Mar 9 '18 at 20:28

# MY, 73 bytes

Here's the hex:

07 24 21 21 28 26
0A 24 21 28 26
0B 24 20 20 28 26
0B 24 20 20 28 26
0B 24 21 28 26
04 24 21 21 21 21 28 26
02 25 28 26
09 24 20 20 20 28 26
0B 24 21 28 26
07 25 21 21 28 26
0B 24 20 20 28 26
0A 24 28 26
02 25 21 28 26


I didn't want to update my old answer, because this one isn't just a simple one-byte solution that uses a builtin.

How it works: Outputs each character by using the few commands I have interpreted:

• Number Literal: 0x00 - 0x0F
• Minus 1: 0x20
• Times 10: 0x24
• Times 16: 0x25
• Output: 0x26
• Character value: 0x28

# Chip, 174166106 97 bytes

94 bytes for the code + 3 bytes for the flag (-w) which allows execution without input.

!ZZZZZZZZZZZZt
|))))))x)))))f
|)xx)x-))xxxa
|)))))-))x))c
)))))x-))))g
)-))))-x)xd
b e^b^e


Try it online!

Chip is a 2D language inspired by integrated circuits, input and output are broken down into individual bits which travel through gates and across wires.

Ungolfed (134 bytes):

!ZZZZZZZZZZZZt
xxxxxxxxxxxxxh
)))))xx)))))xg
x))))))x)))))f
xxxxxxx)x)xxxe
)x))))xx)x)xxd
x)))))x))x))xc
xxxx)xx)))xxxb
x)xx)xx))xxx)a


How the ungolfed version works:

This implementation encodes the target string Hello, World! as a bit matrix, somewhat reminiscent of core memory. The leftmost column of )'s and x's corresponds to H in the output, the rightmost column to !. The ) is an Or-gate (mapping to a 1 in the output), and the x is a wire crossing (mapping to a 0).

The first row is for timing, and the remaining rows are for each of the bits of the output (the row ending in h is the highest bit, and a is the lowest).

The timing behavior starts with the !. ! produces a single 1-cycle pulse at the beginning of execution. The line of Zs then control the left-to-right propagation of the signal at a rate of one element per cycle, each one corresponding to the transition between consecutive letters of the output. Each Z also sends a signal to the column below. At the end of the timing row is t, which terminates the program, preventing infinite output of null characters at the end.

In the first cycle, the first data column is powered. We see OR-gates ()) on the rows for bits d and g, turning them on; the remaining bits stay off because the wire crosses (x) won't propagate the signal from the top to the left. This gives us 01001000, which is H.

In the next cycle, only the second data column is powered. Rows a, c, f and g turn on much like the bits in the first cycle, and the remaining bits are off. This gives us 01100101, which is e.

This continues all the way across to the right, giving the remainder of the output.

Golfing it:

There's not a lot that could be done here, but there are a few things of note:

• The h row is always off, so that can be eliminated.
• Each row can be trimmed on both ends, removing unnecessary x's, so long as the timing signal can still be propagated downward to rows that need it below. This is why the rows are rearranged; to maximize the trimming that can occur.
• The construct )a is equivalent to simply a, so long as the signal did not need to be propagated downward from the OR-gate.

All other changes are just mashing things around to save single bytes.