Quine: Difference between revisions

Jump to navigation Jump to search
4 bytes added ,  13:01, 13 August 2020
m
no edit summary
(I think it's nice to mention quines in this wiki; similar to: https://code.jsoftware.com/wiki/Puzzles/Quine)
 
mNo edit summary
Line 7: Line 7:


In 2019, [[Nick Nikolov]] proposed to shorten it using the [[commute]] operator:<ref>[https://chat.stackexchange.com/transcript/message/48380903#48380903 Transcript for 2019-01-06] – [[APL Orchard]].</ref>
In 2019, [[Nick Nikolov]] proposed to shorten it using the [[commute]] operator:<ref>[https://chat.stackexchange.com/transcript/message/48380903#48380903 Transcript for 2019-01-06] – [[APL Orchard]].</ref>
<source lang=app>
<source lang=apl>
       1⌽,⍨9⍴'''1⌽,⍨9⍴'''
       1⌽,⍨9⍴'''1⌽,⍨9⍴'''
</source>
</source>


Explanation:<ref>[https://codegolf.stackexchange.com/a/178459/87954 Golf you a quine for great good! – APL (Dyalog Unicode), 18 bytes] – Code Golf Stack Exchange.</ref>
Explanation:<ref>[https://codegolf.stackexchange.com/a/178459/87954 Golf you a quine for great good! – APL (Dyalog Unicode), 18 bytes] – Code Golf Stack Exchange.</ref>
* <source lang=apl inline>'''1⌽,⍨9⍴'''</source> the characters <source lang=apl inline>'1⌽,⍨9⍴'</source>
* <source lang=apl inline>'''1⌽,⍨9⍴'''</source> the characters <source lang=text inline>'1⌽,⍨9⍴'</source>
* <source lang=apl inline>9⍴</source> reshape to shape 9, resulting in <source lang=apl inline>'1⌽,⍨9⍴''</source>
* <source lang=apl inline>9⍴</source> reshape to shape 9, resulting in <source lang=text inline>'1⌽,⍨9⍴''</source>
* <source lang=apl inline>,⍨</source> concatenate with itself, resulting in <source lang=apl inline>'1⌽,⍨9⍴'''1⌽,⍨9⍴''</source>
* <source lang=apl inline>,⍨</source> concatenate with itself, resulting in <source lang=text inline>'1⌽,⍨9⍴'''1⌽,⍨9⍴''</source>
* <source lang=apl inline>1⌽</source> rotate one character to the left, getting the characters: <source lang=apl inline>1⌽,⍨9⍴'''1⌽,⍨9⍴'''</source>
* <source lang=apl inline>1⌽</source> rotate one character to the left, getting the characters: <source lang=text inline>1⌽,⍨9⍴'''1⌽,⍨9⍴'''</source>


== External links ==
== External links ==
trusted
69

edits

Navigation menu