34
\$\begingroup\$

This is a repost of Evolution of “Hello World!”, originally written by user Helka Homba

It should not be closed as a duplicated, due to meta consensus here.

The original was asked over two years ago and was last active more than six months ago. I have permission from Helka Homba to post this here

Since the original, many languages have been invented, and many people have joined the site who have never had an opportunity to answer the original, so I feel that this repost is acceptable.


The challenge is to make a program that prints 2^n to stdout, where n is the number of your program. The catch is that your program must have a Levenshtein distance of 10 or less from the program in the answer submitted before yours.

How This Will Work

Below I will submit the first answer using C#, which prints 2^(n=1)=2.

The next person to answer must modify the code with up to 10 single character insertions, deletions, or substitutions so that when it is run in the language of the new answer, it prints 2^n (with n being the answer number). For example, the 25th answer (let's say it's in Pyth) would print 2^25, or 33554432.

This will continue on until everyone get stuck because there is no new language the last answer's program can be made to run in by only changing 10 characters. The communal goal is to see how long we can keep this up, so try not to make any obscure or unwarranted character edits (this is not a requirement however).

Formatting

Please format your post like this:

#Answer N - [language]

    [code]

[notes, explanation, observations, whatever]

Where N is the answer number (increases incrementally, N = 1, 2, 3,...).

You do not have to tell which exact characters were changed. Just make sure the Levenshtein distance is from 0 to 10.

If you answer in some language or the resulting code is just a mess, do please explain what you did and why it works, though this isn't required.

Rules

The key thing to understand about this challenge is that only one person can answer at a time and each answer depends on the one before it.

There should never be two answers with the same N. If two people happen to simultaneously answer for some N, the one who answered later (even if it's a few seconds difference) should graciously delete their answer.

Furthermore...

  • A user may not submit two answers in a row. (e.g. since I submitted answer 1 I can't do answer 2, but I could do 3.)
  • Try to avoid posting too many answers in a short time frame.
  • Each answer must be in a different programming language.
    • You may use different major versions of a language, like Python 2/3
    • Languages count as distinct if they are traditionally called by two different names. (There may be some ambiguities here but don't let that ruin the contest.)
  • You do not have to stick to ASCII, you can use any characters you want. Levenshtein distance will be measured in unicode characters.
  • The output should only be 2^n and no other characters. (Leading/trailing whitespace is fine, as is unsuppressible output like >>> or ans=)
  • If your language doesn't have stdout use whatever is commonly used for quickly outputting text (e.g. console.log or alert in JavaScript).
  • When the power of two you have to output gets very large, you may assume infinite memory, but not an infinite integer size. Please be wary of integer overflows.
  • You may make use of scientific notation or whatever your languages most natural way of representing numbers is. (Except for unary, DO NOT output in unary)

Please make sure your answer is valid. We don't want to realize there's a break in the chain five answers up. Invalid answers should be fixed quickly or deleted before there are additional answers.

Don't edit answers unless absolutely necessary.

Scoring

Once things settle down, the user who submits the most (valid) answers wins. Ties go to the user with the most cumulative up-votes.

Edit these when you post an answer:

Leaderboard

13 languages

Okx

8 languages

zeppelin

4 languages

Pavel
Jonathan Allan
Kritixi Lithos
Riker

3 languages

boboquack

2 languages

bmarks
Conor O'Brien
Destructible Watermelon
ovs
Tom Carpenter

1 language

ATaco
Blocks
Dennis
dzaima
Erik the Outgolfer
ETHproductions
ghosts_in_the_code
Leo
Lynn
Matheus Avellar
Nathaniel
Qwerp-Derp
R. Kap
Taylor Scott
nimi
Mistah Figgins
PidgeyUsedGust
steenbergh

Languages used so far:

  1. C# (Pavel)
  2. /// (boboquack)
  3. Retina (Dennis)
  4. Jelly (Jonathon Allan)
  5. Pyth (boboquack)
  6. ><> (Destructible Watermelon)
  7. Minkolang (Kritixi Lithos)
  8. Perl (Pavel)
  9. Python (Qwerp-Derp)
  10. dc (R. Kap)
  11. Charcoal (Jonathon Allan)
  12. Self Modifying BrainFuck (Leo)
  13. SOGL (dzaima)
  14. ShapeScript (Jonathon Allan)
  15. Pyke (boboquack)
  16. Ruby (Nathaniel)
  17. 05AB1E (ovs)
  18. STATA (bmarks)
  19. bc (Kritixi Lithos)
  20. Japt (Okx)
  21. 2sable (Kritixi Lithos)
  22. Cheddar (Jonathon Allan)
  23. Pylons (Okx)
  24. Bash (zeppelin)
  25. Pushy (Okx)
  26. CJam (Erik the Outgolfer)
  27. MATL (Okx)
  28. MATLAB (Tom Carpenter)
  29. Octave (Kritixi Lithos)
  30. R (ovs)
  31. JavaScript ES7 (Tom Carpenter)
  32. Convex (Okx)
  33. Mathematica (ghosts_in_the_code)
  34. Pip (Okx)
  35. Stacked (Conor O'Brien)
  36. GolfScript (Okx)
  37. Actually (Lynn)
  38. RProgN (Okx)
  39. Scheme (bmarks)
  40. Element (Okx)
  41. J (Blocks)
  42. Cubix (ETHproductions)
  43. zsh (zeppelin)
  44. VBA (Taylor Scott)
  45. Fish (zeppelin)
  46. Reticular (Okx)
  47. Perl 6 (Pavel)
  48. RProgN2 (ATaco)
  49. PHP (Matheus Avellar)
  50. Jolf (Conor O'Brien)
  51. Haskell (nimi)
  52. Befunge-98 (Mistah Figgins)
  53. Gnuplot (zeppelin)
  54. QBIC (steenbergh)
  55. FOG (Riker)
  56. Qwerty-RPN (Okx)
  57. Korn Shell (ksh) (zeppelin)
  58. Julia (Riker)
  59. Python 3 (Pavel)
  60. Vimscript (Riker)
  61. Dash (zeppelin)
  62. Vitsy (Okx)
  63. csh (zeppelin)
  64. Ohm (Okx)
  65. Bosh (zeppelin)
  66. es-shell (Riker)
  67. Gol><> (PidgeyUsedGust)

This question works best when you sort by oldest.

\$\endgroup\$
  • 2
    \$\begingroup\$ A snippet would really be nice \$\endgroup\$ – Kritixi Lithos Feb 26 '17 at 6:58
  • \$\begingroup\$ @KritixiLithos I don't know how to do those, feel free to edit one in though! \$\endgroup\$ – Pavel Feb 26 '17 at 6:59
  • 1
    \$\begingroup\$ @TomCarpenter that is acceptable, I'm going to make the edit. \$\endgroup\$ – Pavel Feb 26 '17 at 18:53
  • 1
    \$\begingroup\$ Does "Levenshtein distance will be measured in UTF-8 characters" mean that the edit distance is computed between strings of Unicode codepoints (and the "UTF-8" is a red herring, since in this sense it doesn't matter whether you use UTF-8, UTF-16, UCS4 or something else)? \$\endgroup\$ – Sami Liedes Feb 27 '17 at 17:19
  • 1
    \$\begingroup\$ @SamiLiedes pavel responded in chat, it's just unicode codepoints yeah. (i.e. if the code point is different, it's a character difference) \$\endgroup\$ – Rɪᴋᴇʀ Feb 28 '17 at 23:17

68 Answers 68

1
\$\begingroup\$

Answer 1: C#

class HelloWorld {static void Main() {
    System.Console.Write(2);
}}

Pro tip: comment out what you don't need.

Try it online!

\$\endgroup\$
1
\$\begingroup\$

Answer 15: Pyke

"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.
1024p#rint(512);
#0}}//4|
#β”6904”±r«"$2 16384*s

Substitutes two ' for two ", adds two $, substitutes 0* for 2(space) and adds *s. (8)

"A#327;N<." String literal, put on stack "..."$ Is it all lower? No, so put 0 on the stack instead
"/class HelloWorld...#β”6904”±r«" String literal, put on stack
"..."$ Is it all lower? No, so put 0 on the stack instead
2 16384 Numeric literals, put on stack
* Multiply top two numbers on stack, put 32768 on the stack instead
s Sum the whole stack: replace whole stack with 32768
(implicit print stack)

Try it online!

\$\endgroup\$
  • \$\begingroup\$ This has been an exercise in learning a language just enough to get past the challenge :D \$\endgroup\$ – boboquack Feb 26 '17 at 8:38
1
\$\begingroup\$

Answer 19: bc, 165 bytes, distance: 6

2^19#/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.
#1024p#rint(512);
#0}}//4|
#ß”6904”±r«"$2 
#puts 16384 8*/di 2^18

Try it online!

Distance:

  • Hashes on the first and last line (2)
  • 2^19 (4)
\$\endgroup\$
  • \$\begingroup\$ Sorry, my answer above was incorrect. The last digit should be 8 instead of 7. \$\endgroup\$ – bmarks Feb 26 '17 at 9:34
  • \$\begingroup\$ @bmarks Edited the change \$\endgroup\$ – Kritixi Lithos Feb 26 '17 at 9:36
1
\$\begingroup\$

Answer 21: 2sable, 161 bytes, distance: 3

2**20$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.
#1024p#rint(512);
#0}}//4|
#ß”6904”±r«"$2 
#puts 16384 8*di 2^18o8*

Try it online!

Distance:

  • Inserted o (evaluates 2**a where a is the value on top of stack)
  • Inserted 8
  • Removed /
\$\endgroup\$
1
\$\begingroup\$

Answer 22. Cheddar, distance 10

print 2**22
'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.
#1024p#rint(512);
#0}}//4|
#ß”6904”±r«"$2 
#puts 16384 8*di 2^18o8*'

Try it online!

inserted print, changed a 0 to a 2 to print the evaluation of 2**22; inserted a new line and a ' and added a trailing ' wrapping the rest into an unused string.

\$\endgroup\$
1
\$\begingroup\$

Answer 23: Pylons, distance 7

#23#2ejprint 2**22
'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.
#1024p#rint(512);
#0}}//4|
#ß”6904”±r«"$2 
#puts 16384 8*di 2^18o8*'

Try it online!

Added #23#2ej to the start of the program.

Explanation:

#23#     Push the number 23 to the stack
    2    Push the digit 2 to the stack
     e   Calculate 2^23
      j  Print stack as a string and terminate the program
\$\endgroup\$
1
\$\begingroup\$

Answer 25: Pushy, distance 4

2 25e#2ej
printf $[2**24]
#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.
#1024p#rint(512);
#0}}//4|
#ß”6904”±r«"$2 
#puts 16384 8*di 2^18o8*'

Try it online!

Added 2 25e# to the start of the program, and removed #23#.

Explanation:

2       Push 2
  25    Push 25
    e   Power
     #  Print

I don't have a clue why this works... it just does.

\$\endgroup\$
  • \$\begingroup\$ I think you've misunderstood how the distance measurement works. \$\endgroup\$ – Nathaniel Feb 26 '17 at 11:56
  • \$\begingroup\$ Yeah, just noticed the distance is 5, not 4. \$\endgroup\$ – Okx Feb 26 '17 at 11:58
  • \$\begingroup\$ I think that's correct. (Sorry, it looked like you were subtracting the length of #23# from that of 2 25e#N, but I see now that you weren't doing that at all, my mistake.) \$\endgroup\$ – Nathaniel Feb 26 '17 at 12:00
  • 2
    \$\begingroup\$ Wow, someone used Pushy... and the reason this doesn't print other things is because it hits the i, which exits the program, before it can spew out anything else. \$\endgroup\$ – FlipTack Feb 27 '17 at 19:31
  • \$\begingroup\$ @FlipTack I'll try and use it more ;) \$\endgroup\$ – Okx Feb 27 '17 at 19:51
1
\$\begingroup\$

Answer 26: CJam, distance 9

2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß”6904”±r«"$2 #puts 16384 8*di 2^18o8*'

Try it online!

That e# at the start saved me much hassle.

Explanation before the e#:

2 25)# e# Program.
2      e# 2.
  25   e# 25.
    )  e# Increment.
     # e# Power.

Added: )#
Removed: \n\n\n\n\n\n\n

\$\endgroup\$
1
\$\begingroup\$

Answer 28: MATLAB, distance 9

disp(2^28)%2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß”6904”±r«"$2 #puts 16384 8*di 2^18o8*'

Helpfully in the last answer, all of the extraneous code was converted into a MATLAB style comment (%) leaving just 27W as code. This can be converted into code for MATLAB using the disp function to display 2^28 without including ans=.


I used this calculator for the Levenshtein distance because it nicely handles multi-line inputs.

\$\endgroup\$
1
\$\begingroup\$

Answer 30: R, Distance of 9

cat(2**30)#2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß”6904”±r«"$2 #puts 16384 8*di 2^18o8*'

Try it online!

\$\endgroup\$
  • 1
    \$\begingroup\$ cat(2^30) would have reduced the distance to 7 and is more idiomatic. \$\endgroup\$ – Dason Feb 26 '17 at 15:50
1
\$\begingroup\$

Answer 35: Stacked, distance 10

2  35^out (*2 32#e#alert(2**31)//2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Try it online! Changelog:

changed (+3): 2**34 => 2  35
inserted (+4): 35 => 35^out
removed: (+3): ”6904”±r« => 6904±r
\$\endgroup\$
1
\$\begingroup\$

Answer 36: GolfScript, distance 3

2  36?#out (*2 32#e#alert(2**31)//2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Try it online!

Explanation:

Changed 35 to 36 (1)
Changed ^ to ? (1)
Added # (1)
\$\endgroup\$
1
\$\begingroup\$

Answer 34: Pip, distance 5

2**34  (*2 32#e#alert(2**31)//2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß”6904”±r«"$2 #puts 16384 8*di 2^18o8*'*

Try it online!

Changed 2^33 to 2**34 (3)

Added a space (1)

Accidentally removed a trailing ) while copying (1)

Explanation:

2**34 is pretty obvious.

Pip counts two spaces as a comment.

\$\endgroup\$
  • \$\begingroup\$ The mathematica answer had a trailing )--did you remove that? \$\endgroup\$ – Conor O'Brien Feb 26 '17 at 16:00
  • \$\begingroup\$ That must have been a mistake copying. I'll edit the distance, so as not to force others' answers to change. \$\endgroup\$ – Okx Feb 26 '17 at 16:06
1
\$\begingroup\$

Answer 9: Python 2

#327;N.""/class HelloWorld {static void Main() 0{;n***~
#    System.Console.
print(512);
#0}}//4|
#8

A very simple port of Perl to Python, with a distance of 4.

Try it online!

\$\endgroup\$
  • 1
    \$\begingroup\$ Just saying, you could have done *2 for a distance of 2 \$\endgroup\$ – Kritixi Lithos Feb 26 '17 at 7:19
  • 1
    \$\begingroup\$ @KritixiLithos True, but it's below 10 anyway and Python 2 complained about the non-UTF8 char at the end. \$\endgroup\$ – clismique Feb 26 '17 at 7:19
  • \$\begingroup\$ @Qwerp-Derp Don't you mean non-ASCII character? is a UTF-8 character \$\endgroup\$ – Okx Feb 26 '17 at 11:30
1
\$\begingroup\$

Answer 40: Element, distance 6

2 40^`(expt 2 39); ^ exit @ⁿ.óout (*2 32#e#alert(2**31)//2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Try it online!

Added 2 40^`

There are no comments or program terminators added, because Element will only print when it comes across a ` character.

\$\endgroup\$
1
\$\begingroup\$

Answer 41: J, distance: 6

2^41 NB.`(expt 2 39); ^ exit @ⁿ.óout (*2 32#e#alert(2**31)//2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Changed from 2 40^ to 2^41 NB.

\$\endgroup\$
  • 2
    \$\begingroup\$ This outputs perfectly fine on the official J Android app \$\endgroup\$ – Blocks Feb 26 '17 at 19:17
  • \$\begingroup\$ Alright then, it counts! \$\endgroup\$ – Pavel Feb 26 '17 at 19:30
  • 2
    \$\begingroup\$ Looking at this, it also works like echo program|jconsole, which is another way to invoke J code. So it's valid even by that measure. (It has 3 leading spaces, which is fine as per the challenge definition.) \$\endgroup\$ – Conor O'Brien Feb 26 '17 at 19:34
1
\$\begingroup\$

Answer, 43: Zsh, distance 10

#2^41 NB.`(expt 2 39); ^ exit @ⁿ.óout (*2 32#e#a44******O@)//2 25)#e#2ej#
printf $[2**43]
bye
'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n*
**~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Try It Online !

\$\endgroup\$
  • \$\begingroup\$ Well darn, you beat me to it :P \$\endgroup\$ – Taylor Scott Feb 26 '17 at 19:21
  • \$\begingroup\$ @ConorO'Brien thanks for the clarification \$\endgroup\$ – Jonathan Allan Feb 26 '17 at 19:40
1
\$\begingroup\$

Answer 45: Fish (shell), distance 10

Finally, a command line shell for the 90s

(c) fishshell.com

math 2\^45#2^41 NB.`(expt 2 39); ^ exit @n.óout (*2 32#e#a44******O@)//2 25)#e#2ej#printf $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.#1024p#rint(512);#0}}//4|
#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Note that this does not work on TIO Nexus due to lack of white space in ...45#2..., but works just nice on my fish, version 2.0.0.

\$\endgroup\$
1
\$\begingroup\$

Answer 46: Reticular, distance 9

28@P2*Jp;math 2\^45#2^41 NB.`(expt 2 39); ^ exit @n.óout (*2 32#e#a44******O@)//2 25)#e#2ej#printf $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.#1024p#rint(512);#0}}//4|
#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Added 28@P2*Jp;

Explanation:

2         Push 2
 8@P      Push 8th prime 0-indexed (23)
    2     Push 2
     *    Multiply (46)
      J   Exponentiate
       p  Print
        ; Terminate progrma 

Try it online!

\$\endgroup\$
1
\$\begingroup\$

Answer 39: Scheme, distance 9

(expt 2 39); ^ exit @ⁿ.óout (*2 32#e#alert(2**31)//2 25)#e#2ej#printf $[2**24]#'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Added (expt (with trailing space)

Changed 8 to 9

Added );

\$\endgroup\$
  • \$\begingroup\$ Doesn’t this need a print call or something? Or do top-level values get printed in Scheme? (I think that e.g. an answer like 2**39 would be invalid in Python, and this looks similar to that.) \$\endgroup\$ – Lynn Feb 26 '17 at 21:46
  • 1
    \$\begingroup\$ @Lynn Top level values get printed (or so it appears when I click run in Dr. Racket). \$\endgroup\$ – bmarks Feb 27 '17 at 6:45
1
\$\begingroup\$

Answer 55: FOG, distance 8

?92a5*2p@^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ exit @n.out (*2 32#e#a44******O@)//2 25)#e#2ej
#printf("%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024print(2**53)--0;#0}}//4|#6904r"$2 #puts 16384 8*di 2^18o8*'*[[[268*^?>

? does nothing, 92a5* makes 55, 2p@ powers and ends the program, auto-outputting. Also added a newline before #printf.

I inserted 9 before the first 2, 5*2p@ after it.

\$\endgroup\$
1
\$\begingroup\$

Answer 57: Korn Shell (ksh), distance 10

bc<<<2^57 #x??92a5*2p@^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ exit @n.out (*2 32#e#a44******O@) //2 25)
#e
#2ej
#printf("%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024print(2**53)--0;#0}}//4|#6904r"$2 #puts 16384 8*di 2^18o8*'*[[[268*^?>

Try It Online !

\$\endgroup\$
1
\$\begingroup\$

Answer 61, Dash, distance 10

"bc"<<x
2^61 
x
#??92a5*2p@^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ 
exit
 @n.out (*2 32#e#a44******O@) //2 25)
"e
"2ej
:py print(2**60)
"%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024print(2**53)--0;#0}}//4|#6904r"$2 #puts 16384 8*di 2^18o8*'*[[[268*^?>

Changes:

  • Added " after "bc +1
  • Replaced < with a newline +1
  • Appended x +1
  • Replaced 57 with 61 +2
  • Removed # +1
  • Added newline after x +1
  • Added # +1
  • Surrounded exit with newlines +2

Total: 1+1+1+2+1+1+1+2=10

\$\endgroup\$
  • \$\begingroup\$ Can you add an explanation for what you did? \$\endgroup\$ – Pavel Feb 27 '17 at 19:51
1
\$\begingroup\$

Answer 62: Vitsy, distance 9

297*1-^N;"bc"<<x
2^61 
x
#??92a5*2p@^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ 
exit
 @n.out (*2 32#e#a44******O@) //2 25)
"e
"2ej
:py print(2**60)
"%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024print(2**53)--0;#0}}//4|#6904r"$2 #puts 16384 8*di 2^18o8*'*[[[268*^?>

Try it online!

Added 297*1-^N; (9)

Explanation:

2           2
      ^     to the power of
 9          (9
   *        multiplied by
  7         7
     -      minus
    1       one)
       N    print as integer
        ;   terminate program
\$\endgroup\$
1
\$\begingroup\$

Answer 63, C Shell (csh), distance 10

"bc"<<x
2^63 
x
#??92a5*2p@^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ 
exit
 @n.out (*2 32#e#a44******O@) //2 25)
"e
"2ej
:py print(2**60)
"%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024print(2**53)--0;#0}}//4|#6904r"$2 #puts 16384 8*di 2^18o8*'*[[[268*^?>

Erased answer #62 by @Okx (sorry !), changed 61 to 63.

\$\endgroup\$
  • \$\begingroup\$ Dang it, I should've added another character to mess you up :P \$\endgroup\$ – Okx Feb 27 '17 at 20:29
1
\$\begingroup\$

Answer 65, Bosh (Schily Bourne Shell), distance 10

#64º,;S)1'a
"bc"<<x
2^65 
x
#??92a5*2p@^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ 
exit
 @n.out (*2 32#e#a44******O@) //2 25)
"e
"2ej
:
py 
p
r
i
n
t
(2**60)
"%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024print(2**53)--0;#0}}//4|#6904r"$2 #puts 16384 8*di 2^18o8*'*[[[268*^?>

Added #, newline in front of bc, replaced 63 with 65, the rest are dummy newlines.

\$\endgroup\$
1
\$\begingroup\$

Answer 54, QBIC, distance 8

?2^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ exit @n.out (*2 32#e#a44******O@)//2 25)#e#2ej#printf("%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024print(2**53)--0;#0}}//4|#6904r"$2 #puts 16384 8*di 2^18o8*'*[[[268*^?>
  • Removed newline
  • Added # after the `
  • Prepended ?2^54┘
  • Removed Herobrine

for a total Levenstein distance of 8.

The # at the start of the previous answer creates a 'silent string literal' in QBIC: it declares and fills A$, but doesn't use it right away. All the code up until the backtick is placed into that string. There is a backtick in that code, so we need to manually add another # to repeat this trick (with B$).

\$\endgroup\$
1
\$\begingroup\$

Answer 18: STATA, distance 10

/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~
#    System<.Console<.<.
#1024p#rint(512);
#0}}//4|
#ß”6904”±r«"$2 
puts 16384 8*/di 2^18

Added /* and /di 2^18

\$\endgroup\$
1
\$\begingroup\$

Answer 44: VBA, Distance 10

Anonymous immediate window routine that takes no input and outputs to the VBE immediate window.

?2^44'#2^41 NB.`(expt 2 39); ^ exit @n.óout (*2 32#e#a44******O@)//2 25)#e#2ej#printf $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#    System<.Console<.<.#1024p#rint(512);#0}}//4|#ß6904±r"$2 #puts 16384 8*di 2^18o8*'*

Added ?2^43'and recondensed lines

\$\endgroup\$
  • 3
    \$\begingroup\$ Argh, you removed my beloved line breaks again !! \$\endgroup\$ – zeppelin Feb 26 '17 at 19:26
1
\$\begingroup\$

Answer 68, Jellyfish, distance 10

PC68º,;n*:"C"
BBc"<<x
2**66
x
#??92a5*2p@^54┘#--2'3k:'2k*.@2(#"#28@P2*Jp;math 2\^45#2^41 NB.`#(expt 2 39); ^ 
qut()
@n.out (*2 32#e#a44******O@) //2 25)
"e
"2ej
:
py 
p
r1ker
s
n
t
(2**60)
"%d" $[2**43]bye'$/*#"A#327;N<."$"/class HelloWorld {static void Main() 0{;n***~#

Try it online!

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.