Help us escape the quine factory! Put messages into quines

1

1

I've been enslaved in a quine factory. The other workers and I can't communicate with the outside world, we can only slave away making quines all day. The masters will reject any work that isn't a proper quine. I'll have to put messages into the quines I make to let people know we're trapped here.

The Challenge

Help us make a quine that a message can be inserted into. It should be a quine such that when an arbitrary message is inserted at a certain point in its source, it still acts as a quine. With this we can send messages out and get rescued.

The Spec

Your submission should be source code and the char position at which a message can be inserted. (Eg 'between the double quotes' or 'between char 17 and 18' or 'at the end')

It's OK if your code doesn't work with a null message. You can submit it with a placeholder message. The placeholder message doesn't count against your score.

We should be able to insert a message containing any of at least,

ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz 0123456789.,!?

Example

The source template:

C1ever_Qu1'm'ne_C0de

Output:

C1ever_Qu1'm'ne_C0de

Score is 19 bytes. The 'm' is not counted because it is the placeholder message.

A message-quine made from the template:

C1ever_Qu1'Help, Im trapped in a quine factory! Please rescue me!'ne_C0de

Output:

C1ever_Qu1'Help, Im trapped in a quine factory! Please rescue me!'ne_C0de

The more of these we can make each day the better, so shortest submission in chars wins.

Jared K

Posted 2018-06-01T19:22:43.823

Reputation: 893

Question was closed 2018-06-01T19:48:14.323

Print a quine that contains the input is quite related to this as well. – Giuseppe – 2018-06-01T20:35:36.270

Sorry I'm new here and still learning about quines. How would I add a message to the answers in that question? Seems like every char is very carefully chosen and just typing in some new chars would certainly break those quines. – Jared K – 2018-06-01T21:52:04.487

@JaredK Those quines are not all payload-capable (what you're looking for) but many are so it's not really an extension/modification on the other challenge, only a further specification that does not introduce new competitive aspects for which answers should aim. – HyperNeutrino – 2018-06-02T00:55:10.997

@JaredK You can add a comment to answers if you want to "add a message to the answers", but I advise against it because those quines are not all meant to be payload-capable. – HyperNeutrino – 2018-06-02T00:56:27.747

By 'add a message' to the answer I meant 'add a message , or payload as you say, to the quine. It seems like people won't find this challenging. But should we change it to be a dupe of the answer that @Giuseppe linked? It seems like the spec for that question and my question are trying to create the same challenge. That seems like a more useful way to mark is as dupe than linking it to the generalized quine challenge – Jared K – 2018-06-02T01:42:19.277

No answers