"Hello, World!"
Introduction
The classic "Hello, World" challenge. What more can I say?
Rules
- Program takes no input.
- Program outputs
Hello, World!with an optional trailing newline. No other output is accepted.
Shortest submission in bytes wins.
Shakespeare Programming Langua …
6y ago
Vyxal, 2 bytes KH Th …
6y ago
PHP, 13 bytes Hello, Wo …
6y ago
Javascript V8, 888 bytes ```j …
6y ago
HQ9+, 1 byte H Oblig …
6y ago
[Common Lisp], 26 22 bytes …
6y ago
QBASIC, 17, 16 bytes ?" …
5y ago
C# 9, 38 bytes System.C …
5y ago
Perl 5 `-E`, 18 bytes ``` …
5y ago
[Python 2], 20 bytes …
6y ago
[C# (.NET Core)], 60 bytes …
5y ago
05AB1E, 7 bytes ”Ÿ™,‚ï! …
5y ago
LOLCODE, 37 bytes HAI 1 …
6y ago
[C++ (gcc)], 43 bytes …
6y ago
R, 20 bytes ``` cat("Hello …
6y ago
[Bash], 18 bytes ec …
6y ago
SOGL, 10 bytes ╥‰⅜,(ε ‘ū …
6y ago
Stuck, 0 bytes ``` ``` …
1y ago
[Taxi], 183 bytes Go to …
1y ago
Z80 Assembler, 50 bytes ``` …
4y ago
///, 13 bytes ``` Hello, W …
5y ago
[PowerShell], 15 bytes …
5y ago
[RoadLang], 59 bytes …
6y ago
AppleScript, 15 bytes " …
6y ago
[JavaScript (V8)], 28 bytes …
6y ago
[ARBLE], 15 bytes " …
6y ago
Japt, 11 bytes `HÁM, W …
6y ago
Raku, 19 bytes ``` "Hello, W …
6y ago
[Python 3 (PyPy)], 21 bytes …
6d ago
[Emmental], 51 bytes ```non …
1y ago
[C (gcc)], 30 bytes …
2y ago
C (gcc), 46 bytes ```cpp pri …
4y ago
SOS, 155 Bytes !+!-!!+! …
4y ago
J, 15 bytes ``` 'Hello, Wo …
4y ago
[dc], 16 bytes [Hello, …
5y ago
[Seriously], 1 byte H …
5y ago
[Unlambda], 40 bytes `` …
5y ago
[Haskell], 25 bytes …
5y ago
Turing Machine.io, 202 bytes …
5y ago
Scala, 42 bytes object>e …
5y ago
[C# (.NET Core)], 67 bytes …
5y ago
Rockstar, 19 bytes say …
5y ago
PureScript, 25 bytes ``` m …
5y ago
Swift, 23 bytes ```swift p …
5y ago
Kotlin, 34 bytes ```kotlin …
5y ago
[Forth (gforth)], 16 bytes …
5y ago
HTML, 26 13 bytes ``` Hell …
5y ago
[K (oK)], 15 bytes "Hel …
2y ago
[AWK], 2 bytes $0 Tr …
2y ago
JavaScript V8, 26 bytes ``` …
4y ago
[shortC], 16 bytes AJ"H …
5y ago
[jq] `--null-input` `--raw-out …
5y ago
[SQLite], 21 bytes sele …
5y ago
[Emoji], 24 bytes 💬Hell …
5y ago
[Sclipting], (UTF-16) 18 bytes …
5y ago
[Java (JDK)], 80 bytes …
5y ago
[Chef], 558 485 bytes H …
5y ago
[Forget], 319 bytes pus …
5y ago
Lean, 64 bytes ```lean def …
5y ago
[!@#$%^&()+], 17 bytes …
5y ago
[Pyth], 14 bytes "Hello …
5y ago
Bash, 21 Bytes ```bash pri …
5y ago
[Charcoal], 13 bytes He …
5y ago
Java, 37 Bytes ```java v-> …
5y ago
[Lua], 20 bytes pri …
5y ago
65 answers
Raku, 19 bytes
"Hello, World!".say
Explanation
First second answer of the.. entire site, actually. Nothing special. I don't think this can go shorter, but this is Raku, who actually knows. I made this post to (possibly) try and set a precedent for what a answer should look like. Obv you don't have to explain it, but it's nice.
RoadLang, 59 bytes
wagwan my slime
man say"Hello, World!"
chat wit u later fam
My first RoadLang answer! And probably the first one on this site!
Removing any of the words says "Aight the lad's lost the plot", so I think this is the most minimal answer I can get here.
Thanks to Quintec for patching string parsing so that this works.
0 comment threads
Z80 Assembler, 50 bytes
org 256
ld de,m
ld c,9
jp 5
m:db"Hello, world!\r$"
With assembler there's usually the problem which machine or operating system the program is for. I've chosen CP/M here as it runs on a variety of different machines with a Z80 processor.
CP/M programs start at address 0x100, but the decimal representation 256 is shorter.
The program loads the address of the $-terminated string into the D & E register pair, then the number of the print text subroutine (9) into the C register, and jumps to the BDOS entry. It uses the RETurn of that routine to end itself, instead of CALLing the BDOS and needing an own RET instruction in the program.
0 comment threads
AppleScript, 15 bytes
"Hello, World!"
No, I'm not joking. This ridiculous language for a code golf actually beats some of the more normal languages.
0 comment threads
Stuck, 0 bytes
That's it.
An empty program in Stuck prints "Hello, World!". It's literally hardcoded in the interpreter.
J, 15 bytes
'Hello, World!'
Or if you prefer to beat around the bush...76 bytes.
{:a.{~-:^:_1@:|.~&2 S:0<@:<\50 16.5 36 50.5 54 54 55.5 22 16 43.5 55.5 57 54
0 comment threads
Scala, 42 bytes
object>extends App{print("Hello, World!")}
0 comment threads
Turing Machine.io, 202 bytes
0 1 101 3 1 2 0
0 2 108 3 1 3 0
0 3 108 3 1 4 0
0 4 111 3 1 5 0
0 5 44 3 1 6 0
0 6 32 3 1 7 0
0 7 87 3 1 8 0
0 8 111 3 1 9 0
0 9 114 3 1 a 0
0 a 108 3 1 b 0
0 b 100 3 1 c 0
0 c 33 3 1 0 1
Basically just keeps replacing the current cell value with the ASCII value of whatever character in "Hello, World!" its printing and moving on. I might add a more detailed explanation later (or maybe someone else can, if they feel like it).
0 comment threads
C# (.NET Core), 67 bytes
class a{static void Main(){System.Console.Write("Hello, World!");}}
0 comment threads
Rockstar, 19 bytes
say "Hello, World!"
Try it here (Code will need to be pasted in)
0 comment threads
C (gcc), 30 bytes
main(){puts("Hello, World!");}
This is using GNU C extensions. GNU C allows main() over int main(), ss well as using puts without including stdio.h.
0 comment threads
C (gcc), 46 bytes
printf(char*);main(){printf("Hello, World!");}
printf(char*);(14 bytes) is better than
#include <stdio.h>\n(19 bytes)
- ← Previous
- 1
- 2
- 3
- 4
- Next →

1 comment thread