Edit 2020-11-06: This challenge has been edited with new provisions to encourage participation. The edits have been bolded for emphasis.
Welcome to a cops and robbers version of Find an Illegal String.
An illegal string is "a string of characters that cannot appear in any legal program in your programming language of choice" (from the linked post).
For this challenge, we will define an almost illegal string, which is a string of characters that is very hard, but not impossible, to include in a valid program.
The Cops' Challenge
- Choose a programming language, and choose an 'almost illegal string' - this is a sequence of characters that is very hard to include in a valid program without causing it to error.
- Write a program that contains the 'almost illegal string' as a contiguous substring that does not error.
- Optionally, you may also specify a set of banned characters. These are characters that do not appear in your program, except in the 'almost illegal string'. (Therefore: banned characters can still appear inside the almost illegal string)
That's it! You will reveal the programming language, the almost illegal string, and the set of banned characters, and challenge robbers to write a program that contains the illegal string but does not error.
For the purposes of this challenge, we define 'does not error' as:
- Your program exits with exit code 0.
- Your program does not print any output to standard error.
- Your program may print anything to standard output, if you wish, but it does not have to.
- If (and only if) your language always prints output to standard error regardless of the program, such as debugging or timing information, you may instead design a program that only outputs this to standard error. If you are making use of this clause, mention it in your cop post.
The Robbers' Challenge
Find an uncracked answer. Write a program in the language specified that contains as a contiguous substring the almost illegal string specified and does not error. Your program may not use any character in the set of banned characters, unless it is part of the almost illegal string. Your program does not need to be exactly what the cop had in mind. Post an answer to the robber's thread and leave a comment on the cops' answer to crack it.
Clarifications
- If your cop answer requires a specific operating environment or version, you must specify this in your answer.
- The cop's almost illegal string that they reveal is to be interpreted with respect to the standard encoding for the language's interpreter. For most programs, this will be UTF8.
- Solutions should not take any input (via standard input, argv, or any other source) and may assume no such input is given.
- Solutions must terminate in a finite amount of time. This means entering an infinite loop and getting killed by TIO's 60 second timeout is not a valid solution.
- Cops should make sure if their almost illegal string contains leading or trailing newlines that it is very clear it does so. Robbers should carefully note any leading or trailing newlines in a cop's post.
Formatting hint
The clearest way to include leading or trailing newlines is to use the backtick syntax for your post:
```
foo
```
Renders as:
foo
To remove any ambiguity, explicitly mention the leading/trailing newlines in your post.
Scoring
After 10 days without a crack, a cop can mark their answer as safe and reveal their solution. Once the cop has revealed their solution, it is no longer able to be cracked.
Cops are scored based on the length (in bytes) of their almost illegal string in their safe answer(s), with lower being better.
Robbers are scored by the number of answers they crack, with higher being better.
Example
Python 3, 5 bytes
Illegal string:
"'1/0
Banned characters:
#'
Python 3, cracks example's answer
Program:
""" "'1/0 """
The idea is that we can just comment out the string, since "
is not banned.