"Hello, World!" (Cops' thread)

TeX - 38 bytes Cracked(ish)

This is worth a shot, because I can't imagine anyone on a site about writing short pieces of code would know TeX:

\read16to\x\message{Hello, World!}\bye

To run it, you should get a hold of some form of TeX that allows interactive mode. Save this to a file, and run TeX (or pdfTeX, XeTeX, etc.) on it.

Edit: I'm currently considering this semi-cracked. The intended solution uses input from stdin, but TeXnically input from the way the program is invoked is valid. I'll be adding more devious TeX answers if someone gets the intended method.

Here's the intended solution:

^C Ia - The first key is control-c, which causes an error. Then, you press I (capital i) to input a command. Then you type a (or anything else to be typeset). Normally, the message that was printed to stdout would be followed by a space and then a ')'. When you typeset something, it causes the font information to be output after the message. That means that a newline is thrown in, and the ')' gets moved later.

That may be underhanded, but should still be within the rules of the game.


><>, 538 bytes, Cracked by rexroni

v
\">/v>v\v</>"
/!?lp%*2di%*2di
a
v   "        "       "
   "l"      "o"  /  "e"
v   "        "     " "
      "   /       "l"/
v    "!"           "
 //   " " "      \
v     \"d"o"   " "    "
      " " "   "o"r"  "!"
v"   "H"       " "    "
"l"   ""
""    "r" "         "
    \  " "l"       "d"  "
v   "     "      "  "  "H"
   "e"         /","     "
v " " "     "  " "
 "e" "W"  /"d""l"
v " " "     "  "      "
   "H"               "!"
v   "                 "
                        v
>>"Hello world?"       >o<
                        ^

Try it online, or you may want to use the fish playground.

The first three lines read in a string from STDIN and use its charcodes mod 26 as coordinates to put the characters ">/v>v\v</>" into the maze below. The intended solution is a 20-character string made of the letters A–Z only (although you're allowed to use anything you want, of course).

Solution:

The intended input is OCEANICWHITETIPSHARK (it's a fish!). The path through the maze looks like:

v
\">/v>v\v</>"
/!?lp%*2di%*2di
a                |  |
v   "        "   |  |"
| v"l"______"o"__/  "e"
v | "        "     " "
| |   "   /       "l"/
v |  "!"           "|
|//   " " "    v_\  |
v|    \"d"o"   " "  | "
||    " " "   "o"r" |"!"
v"   "H"       " "  | "
"l"___""_______ _/__/_____
""    "r" "    | |  "
|>__\  " "l"   | | "d"  "
v   "     "    | "  "  "H"
|  "e"v________/"," |   "
v " " "     "  " "  |
|"e"|"W"  /"d""l"|  |
v " " "     "  " |  | "
<  "H">__________ __\"!"__
v   "            |  | "
    >____________ __ ___v
>>"Hello world?" |  |  >o<
                 |  |   ^


Octave, 59 bytes, Cracked

This works in Octave 4.2.0. I can't guarantee compatibility with all versions.

i=input('');printf('%c',i*~all(isequal(i,'Hello, World!')))

Note: This doesn't print any trailing spaces or newlines. This is what it looks like:

enter image description here

It basically says: "Print the input string, unless the input is 'Hello, World!', in which case it should print nothing (or the null-character).