tail

after biting something off, you're left with the rest of the text. it's the tail.

this language bites off "pasta" and emits out the tail.

TRANSLATED:



it's easy. it's very SIMILAR to the bite language, but this time we emit the tail instead of the head.

function bitePastaAndEmitTail(text) {
	if (text.startsWith("pasta")) {
		return text.slice(5)
	}

	throw new Error(`TERRIBLE error: expected 'pasta' but found '${text.slice(0, 5)}'!`)
}

back to the dream