This challenge is inspired by @LuisMendo's MATL answer to my "binary multiples" challenge.
Pick a code-golf challenge that is open and that has been posted before this one; let me call it the "linked challenge". The linked challenge must be a challenge whose task involves producing output.
Write the shortest code possible that satisfies the following restrictions:
- Your code must contain the characters
gin your program, in this order and consecutively (case-insensitive, so "bug", "BUG", "Bug", "bUg", ... are all fair game.);
- Your code must not contain the letters
gmore than once (case-insensitive);
- Your code should be a valid submission for the linked challenge;
- When any subset of the (case-insensitive) characters
bugare removed, your program no longer fulfils the task of the linked challenge. This may happen because your program now produces the wrong output (i.e. fails test cases), because it halted with an error, because it runs indefinitely and never returns (if this is the case, be prepared to prove your program runs indefinitely), etc.
- Your code should not be an integral copy - nor a trivial modification* - of a submission that already exists in the linked challenge (for example, you may not copy @LuisMendo's MATL answer to my "binary multiples" challenge);
Your program takes input as per the specs of the linked challenge you choose.
Your program, in its correct state (i.e. with a bug**), must abide by the output specs of the linked challenge you choose.
* This is subjective so I appeal to your common sense; any imaginative modification should be fair game, even if in retrospective it is "trivial". This "no trivial modifications" rule will be "enforced" by me downvoting answers I think disrespect this...
** Sit down, take a moment to let this sink in. Your program has a bug. And yet your program is correct.
Posting an answer
When you post your answer, please provide a link to your linked challenge.
This is code-golf so shortest submission in bytes, wins! If you liked this challenge, consider upvoting it! If you dislike this challenge, please give me your written feedback. Happy golfing!
Trueby default. Removing some of its
bugwill obviously be an error. Though I can't find a suitable challenge for that... \$\endgroup\$