The Poetry of Code
Published: 2016-06-01 11:50:45

<p>This is not a philosophical point about programming being as beautiful as Shakespeare sonets. This is real poetry made with code. Started as an unofficial initiative within Java developer community of Vilnius, Lithuania, <a href="http://www.sourcecodepoetry.com/" target="_blank">Source Code Poetry Challenge</a> was first held in 2013 and has been evolving ever since.</p>
<p>Source Code Poetry is an initiative that encourages software developers to write code that rhymes, has poetic rhythm, and fascinate us.  We show off how creative developers are and how multidimensional programming languages can be.</p>
<p>Let us examine some of historic submissions. Those do speak louder than any words.</p>
<p><img style="display: block; margin-left: auto; margin-right: auto;" src="http://res.cloudinary.com/db3xv3aov/image/upload/c_scale,w_712/v1464779680/Done_lean_yfgygp.png" alt="&quot;The American C&quot; by Done Lean" width="712" height="712" /></p>
<p>It is a C++ poem about the deep nostalgic feelings the author has towards the now-gone era of classic C; and about the new scary times brought in by the C++ &ndash; which &ldquo;spoiled&rdquo; and &ldquo;broke&rdquo; the innocence of ancient art of software development.
</p>
<p>
From a technical perspective, the poem is a pure nugget: there are neither <code>#includes</code> nor <code>#defines</code>, nor any other boilerplate code &ndash; the whole text is a smooth human-readable text. Author only uses the &ldquo;class&rdquo; keyword to make his point &ndash; classes are unnecessary for writing good code (there&rsquo;s no such thing that couldn&rsquo;t be coded in the bytecode as well).</p>
<p>&nbsp;<img style="display: block; margin-left: auto; margin-right: auto;" src="http://res.cloudinary.com/db3xv3aov/image/upload/c_scale,w_712/v1464779878/10302637_302516546581698_3477359028805837702_n_nr7bt6.png" alt="by Droggl" width="712" height="712" /></p>
<p>Another one, from 2014, a mind-bending C++ code by German academic Droggl: one obvious attempt to trigger cognitive dissonance inside the brain of a C/C++ programmer.</p><p>When trying to code-review this piece, all the shaky fragments rhyme in your head as you go from one line to another, from one keyword to the next &ndash; all the way convincing yourself it should NOT compile, yet it still somehow does. To tell why it compiles when it should not, you have to read it several times. </p>
<p>It is hard to tell its poetic value exactly; however chances are you will never be the same C++ coder again after spending enough time analyzing this stuff: cpp keywords you&rsquo;ve known for many years do rhyme.</p><p>Bjarne Stroustrup must have intentionally designed The Language this way.</p>
<p>Each year the competition is different from the ones before. This year it is dedicated to Shakespeare's 400th death anniversary. Thus, submissions have to be related to the great wordsmith one way or another. Just like this year's submission by Lector George: All we received was an HTML file with complete text of "Hamlet" in it. After checking the Console tab we found something we'd never expect to find - a hidden "roses are red..." message.</p>
<p><img src="http://i.imgur.com/Z4I6Tac.png" alt="by Lector George" width="750" height="719" /></p>
<p>"It's straightforward. All this Javascript code does is decipher the hidden message within the English text of the immortal Hamlet. As you can see, the message was hidden there all the time - for more than four centuries." - author says.</p>
<p>When picking best submissions, the decision is far from easy for the jury board. Important aspects &ndash; such as humor, technical implementation, overall emotional impact, storyline, originality, poetic value &ndash; are all subjects to the human interpretation.</p>
<p>The competition is still ongoing. Even though it's only a few days left, everyone is welcome to submit their masterpieces. The jury board is waiting with their breath bated. </p><p>See more submissions, prizes, get to know jury board members at <a href="http://www.sourcecodepoetry.com/" target="_blank">sourcecodepoetry.com</a></p>
<p>Submit your entry to <a href="mailto:art@sourcecodepoetry.com" target="_blank">art@sourcecodepoetry.com</a> BEFORE June 6th.</p>