"Black Perl" is a code poem written using the Perl programming language. It was posted anonymously to Usenet on April 1, 1990, [1] and is popular among Perl programmers[ citation needed ] as a piece of Perl poetry. Written in Perl 3, the poem is able to be executed as a program.
"Black Perl" has been discussed in several scholarly works, [2] [3] [4] and is considered an example of generative literature, a genre of electronic literature.
When posted to the comp.lang.perl
newsgroup the poem was attributed to "a person who wishes to remain anonymous". [1] Sharon Rauenzahn (née Hopkins), another Perl poet, has been suspected to be the author but has since denied the claim. [5]
When executed, "Black Perl" exits on line one, upon reaching the function exit. The remaining lines are parsed by the Perl interpreter but never actually executed. The program produces no output.
Though it will not parse under Perl 5, multiple independent updates to "Black Perl" to make it parsable in Perl 5 have been published. [6] [7]
BEFOREHAND:closedoor,eachwindow&exit;waituntiltime.openspellbook,study,read(scan,select,tellus);writeit,printthehexwhileeachwatches,reverseitslength,writeagain;killspiders,popthem,chop,split,killthem.unlinkarms,shift,wait&listen(listening,wait),sorttheflock(then,warnthe"goats"&killthe"sheep");killthem,dumpqualms,shiftmoralities,valuesaside,eachone;diesheep!dietoreversethesystemyouaccept(reject,respect);nextstep,killthenextsacrifice,eachsacrifice,wait,redoritualuntil"all the spirits are pleased";doit("as they say").doit(*everyone***must***participate***in***forbidden**s*e*x*).returnlastvictim;packagebody;exitcrypt(time,times&"half a time")&closeit,select(quickly)&warnyournextvictim;AFTERWORDS:tellnobody.wait,waituntiltime;waituntilnextyear,nextdecade;sleep,sleep,dieyourself,dieatlast
Bash, short for Bourne-Again SHell, is a shell program and command language supported by the Free Software Foundation and first developed for the GNU Project by Brian Fox. Designed as a 100% free software alternative for the Bourne shell, it was initially released in 1989. Its moniker is a play on words, referencing both its predecessor, the Bourne shell, and the concept of renewal.
MUMPS, or M, is an imperative, high-level programming language with an integrated transaction processing key–value database. It was originally developed at Massachusetts General Hospital for managing patient medical records and hospital laboratory information systems.
Perl is a high-level, general-purpose, interpreted, dynamic programming language. Though Perl is not officially an acronym, there are various backronyms in use, including "Practical Extraction and Reporting Language".
rn is a news client written by Larry Wall and originally released in 1984. It was one of the first newsreaders to take full advantage of character-addressable CRT terminals. Previous newsreaders, such as readnews, were mostly line-oriented and designed for use on the printing terminals which were common on the early Unix minicomputers where the Usenet software and network originated. Later variants of the original rn program included rrn, trn, and strn.
On Unix and Unix-like computer operating systems, a zombie process or defunct process is a process that has completed execution but still has an entry in the process table: it is a process in the "terminated state". This occurs for the child processes, where the entry is still needed to allow the parent process to read its child's exit status: once the exit status is read via the wait
system call, the zombie's entry is removed from the process table and it is said to be "reaped". A child process initially becomes a zombie, only then being removed from the resource table. Under normal system operation, zombies are immediately waited on by their parent and then reaped by the system. Processes that stay zombies for a long time are usually an error and can cause a resource leak. Generally, the only kernel resource they occupy is the process table entry, their process ID. However, zombies can also hold buffers open, consuming memory. Zombies can hold handles to file descriptors, which prevents the space for those files from being available to the filesystem. This effect can be seen by a difference between du
and df
. While du
may show a large amount of free disk space, df
will show a full partition. If the zombies are not cleaned, this can fill the root partition and crash the system.
In computer science, control flow is the order in which individual statements, instructions or function calls of an imperative program are executed or evaluated. The emphasis on explicit control flow distinguishes an imperative programming language from a declarative programming language.
Ousterhout's dichotomy is computer scientist John Ousterhout's categorization that high-level programming languages tend to fall into two groups, each with distinct properties and uses: system programming languages and scripting languages – compare programming in the large and programming in the small.
Laurence A. Canter and Martha S. Siegel were partners in a husband-and-wife firm of lawyers who posted the first massive commercial Usenet spam on April 12, 1994.
In computer programming, the Schwartzian transform is a technique used to improve the efficiency of sorting a list of items. This idiom is appropriate for comparison-based sorting when the ordering is actually based on the ordering of a certain property of the elements, where computing that property is an intensive operation that should be performed a minimal number of times. The Schwartzian transform is notable in that it does not use named temporary arrays.
Elvis is an enhanced clone of the vi text editor, first released in January 1990. It introduced several new features, including syntax highlighting and built-in support for viewing nroff and HTML documents. Elvis is written by Steve Kirkendall and is distributed under the Clarified Artistic License (ClArtistic) which is used by Perl and is a GPL-compatible free software license.
Berkeley Yacc (byacc) is a Unix parser generator designed to be compatible with Yacc. It was originally written by Robert Corbett and released in 1989. Due to its liberal license and because it was faster than the AT&T Yacc, it quickly became the most popular version of Yacc. It has the advantages of being written in ANSI C89 and being public domain software.
In computer science, the syntax of a computer language is the rules that define the combinations of symbols that are considered to be correctly structured statements or expressions in that language. This applies both to programming languages, where the document represents source code, and to markup languages, where the document represents data.
Leonard "Len" H. Tower Jr. is a free software activist and one of the founding board members of the Free Software Foundation, where he contributed to the initial releases of gcc and GNU diff. He left the Free Software Foundation in 1997.
A Usenet personality was a particular kind of Internet celebrity, being an individual who gained a certain level of notoriety from posting on Usenet, a global network of computer users with a vast array of topics for discussion. The platform is usually anonymous, although users can get celebrity status, usually by being deemed different from other posters in some way.
Usenet, USENET, or, "in full", User's Network, is a worldwide distributed discussion system available on computers. It was developed from the general-purpose Unix-to-Unix Copy (UUCP) dial-up network architecture. Tom Truscott and Jim Ellis conceived the idea in 1979, and it was established in 1980. Users read and post messages to one or more topic categories, known as newsgroups. Usenet resembles a bulletin board system (BBS) in many respects and is the precursor to the Internet forums that have become widely used. Discussions are threaded, as with web forums and BBSes, though posts are stored on the server sequentially.
Code golf is a type of recreational computer programming competition in which participants strive to achieve the shortest possible source code that solves a certain problem. Code golf challenges and tournaments may also be named with the programming language used.
The Perl virtual machine is a stack-based process virtual machine implemented as an opcodes interpreter which runs previously compiled programs written in the Perl language. The opcodes interpreter is a part of the Perl interpreter, which also contains a compiler in one executable file, commonly /usr/bin/perl on various Unix-like systems or perl.exe on Microsoft Windows systems.
Hamilton C shell is a clone of the Unix C shell and utilities for Microsoft Windows created by Nicole Hamilton at Hamilton Laboratories as a completely original work, not based on any prior code. It was first released on OS/2 on December 12, 1988 and on Windows NT in July 1992. The OS/2 version was discontinued in 2003 but the Windows version continues to be actively supported.
Snake case is the naming convention in which each space is replaced with an underscore (_) character, and words are written in lowercase. It is a commonly used naming convention in computing, for example for variable and subroutine names, and for filenames. One study has found that readers can recognize snake case values more quickly than camel case. However, "subjects were trained mainly in the underscore style", so the possibility of bias cannot be eliminated.
Code poetry is literature that intermixes notions of classical poetry and computer code. Unlike digital poetry, which prominently uses physical computers, code poems may or may not run through executable binaries. A code poem may be interactive or static, digital or analog. Code poems can be performed by computers or humans through spoken word and written text.