How could a quine in my programming language look?

Posted by ads on Stack Overflow See other posts from Stack Overflow or by ads
Published on 2010-04-11T18:50:39Z Indexed on 2010/04/11 18:53 UTC
Read the original article Hit count: 378

Filed under:
|

I have created a turing-complete programming language (already proven) so it must be possible to write a quine for it, right?

But all quines I know store their source code in a string and then replace a special character in it using something like chr and ord.

My language only has the following

  • Basic arithmetics
  • Int and string types
  • Variables
  • == operator
  • Conditional gotos

I have no idea how I could write a quine as I have no real string manipulation available, I can only output constant strings. Yet, it is 100% turing-complete.

© Stack Overflow or respective owner

Related posts about quine

Related posts about turing-complete