HI9+ is a derivative of HQ9+ created by User:Rdococ. Rather than having a quine command, rdococ thought it would be more useful if there was an interpreter command that printed the source code of the interpreter. Thus, the I.
Take this quote from HQ9+:
- Although the language is not of serious interest by itself, it can be useful to implement HQ9+ in a new esoteric programming language, since doing so proves that all the tasks above, except the quine, are possible.
HI9+ fixes the quine issue, so an implementation of HI9+ in a new esoteric programming language proves that the quine is possible in that language (although there is still the issue that the language may be unable to quine at an arbitrary point).
Hprints the message
Hello, world!(as opposed to
hello, worldin HQ9+)
Iprints the interpreter's source code.
9prints the lyrics to "99 bottles of beer."
+increases the accumulator.
Quines in HI9+
- Not to be confused with the mention of the quine issue above.
Only some implementations of HI9+ support quines, and the most notable one is the one whose source code is
I, in which
I is a quine.
Some implementations may ignore characters which are not in the instruction set, rather than halting or giving an error - those support the additional quine,
Additionally, if an implementation gives an error and subsequently halts upon receiving an invalid instruction, and the error message it prints does not begin with a valid instruction, the error message itself counts as a quine.
Finally, if the aforementioned (error & halt on bad instruction) interpreter still prints the output that the code prints before the error itself, the lyrics to "99 bottles of beer" repeated twice followed by the error message would also be a quine - and in this circumstance, even if the error message begins with a valid instruction.