text:
Looking for programs in a huge Boggle board
Each character in this 64 by 64 block of text has been chosen randomly and uniformly from the 95 printable ASCII characters.
/rq$:Zy5*g'$DeGXX2o8y "{@Cg:FR9qih}xh >5$DsF1Fs5Ao~smFp;.RJbV )U
c4\(|Sx*V$10G9xO:NjHKasem%,\9[pPm@&kTaN~HC[;9`lgqlAH(7dt0a-5}LJ[
&sifw9V-.PLRoD~F'dJYA^Q)L#h>$9h!B4b&ceKp8~HndzDm#1/ySydrf5T8[Y%4
U9>HLQ74Qf[^V9tpWrKFcFxZJ::4?z/o]3u,V[B&hB9lFYA0:rW#yql5z9.d*D}U
:M2*O9'7_HMGw_=%@hR>O+(@Dr6MIt(=/{-{4lia0Vmws32wr(fnTmT%HSo&7!uz
\KZWG&KnXh+6E+Q>%pV(<Bnm-d+p~y~]Ta"aw9)]0A_AHz\tP3&}1R^/yPPSgN?8
".7|Uj)S7-k[`yeLO~P2a?z3wiS(R-\k'?z(pVm;;D^k/q84?&7:,E*9$UQ"UbBJ
ME]&*R ,*7PDF4Tw*-;De{YeP_al.CJcJX`@V_y+>^<h{L[^Y"!RxjN^lyA_/Y=(
#C>Zo#Sl;UUD5ChIj'L@rkELk%S*]a$87j\\n;}796m/\NPL>8d-T-hR!7ftw ?A
tV5"E309bAv$jhE6\'8f?VGlBb?z#V;F((3'|}$tfpiNB>"*mxc,X1s:/%x*JQAL
rxYXUJsd?X}^yc|'16539vd=psU'>|y/!$-TRamKcJk^2-aD35h7CcaRNue"8#{;
@yUq?*(72I8@I)So+]RwtKy:mLhjG/f#:U<TXml<PtX*+,ngfZt75-q*gSsyI2tS
|*M*;yz6u2(LZ>W`bth-7G~>|dh'pm}]@"#Oq9%o\W)b,gh%b1O]4F:EGb7ERI=@
ehMo69slKw=S@<j*Q4sfd\1')#)V&yaPF%%ZG6VK\_-$Cab,nrlW"O(<tu&xU=I&
|[g4k2L;FD)=yX0SsE-|vI(mDOccuU(+m\wxgrJxi8ZP[uD)L.!K@]%@q`!pk8Yx
?PZaS3;x,7nK~IHlrCGy~xq:@K/CJ1J^oeac&Tv?6[H>>0lu?(/bh@6J^@S?IY-|
@tdN$K=Ci2;_0Du;L2OO'en|]<_`nX5p3Bes9`8{}fRCV$X&aoQGYS'$j%r<2709
UwETsAo^d!aUZ0vN5,Yq\n%JAIm}%O88FAJK^Jt&=jM\Q1^+^|X8\._"l%hlF+yH
+c^FBFxTGz|f|#kElQs)mS64-3Z\An]|[rQo"OQ+ IP"ARdJ}/OYFQF_/{B 73mU
UPvxNByN[2TT,XgRZ_LwolUVWuR)DjYI7j#mmA8m?&Y}}[_h8@Y-R*,#=1\D*&@*
ePW.w{@z3moe3Vztd,>?*~ZQUvn8$+xw$$f92D*kPZ":;lcTr3m&{*?j$FgZK|cU
IAd'0C{<4b}NuhX1B#gmk'oF4+(@fzP^T?hF/#]g^y rb5][)X-d4Q't~1]HE"tZ
p2Z,%H0$EWF/%|UQm?&]E~=v;9YwxrSs%}df`[ `SfXMJWt86UY1duGAAKkFSrH!
oUyB[soS!N%XYwX]%n K^}CcTE?~.,8`C&l)Jjjp5|z))!o/ "G)sj,{OETsi:KE
4E,':a=,T~YlxdF^<\$fE|f:_-RG}7=m%g\-9a*X]`n<P$D+q7O`+$P&!\"NUs7n
hL@0s 7i^Xp\._4$lZIB9Ql AXX_00K=<hp%55KSO6yWH~cGe%|(p_WzlhPUbH{?
o5b4pi(,]&&jB\hGa:\DQbrYc,n|,b)_E{n~i~+JSxn?%/qJVm|B 8"Jf||L.|M-
 KRxH;T^Z7%ZufyO=nI;[v1\8ZTg\_)ect4DvMTvqtoo(;b~J&'~E2TTD!w1BvGv
Q+1sv>q%1$BaCm%(\%uGH*]emoFwejkhb$gKm=DVG#&:p'";s)&MY30q_cG=.CKJ
q,aWTi|^w2wg3<G_y<n+^Xq2ymHFs#7z[x0l'Lz6N>Mpo?=hAd&58HVMhsh(kQH5
&kSivkn`,KON9xb:$M[L15!D6W?\ASWc#}V#2U;qxKhtil73,!iuG~(lr[tPJQ6w
IZ)0Vp{kEUID:vgwmTMQ#Y]NdX6{'/3bI2x9k 4[>j)&Q0U,t,iA#A%4929o6+n_
SQe/!KubbuXthMe&2\%:'Z`,aaA)V&(v+]0^v-_@*Qg!^K!pCo"@e/|3}.3q^R||
6hF>/jd>(=il~2$KY.^x~K_H)J8Fi)'LOcUr4xJir^v0,c fIsoT<|7K}Bls|36z
MQ|-w=bp)_EY>YtGcW)!@/|Lc:I_<]x.~[|QSgJY1ZX9^e`ojAR6U#zt9!,44}>#
EJzH \gwosC>Z*)H!]1BPaIEYGyk{c0zv{d\#px2@#'-T{{.Qxknxv}"x3#K]w>;
<X(\bNnY_6*7Yu7_3a+wInwt vh=1eBgz>7Bnhs!<t.T#&V{+?p+{.RTN:xz>|,E
$upN*[F4A`~ZDMDt{.&2z+LZ7bcfeJfF9Uy3xX]ZzQ1FvB.U4S!hm$LYCp: wF7h
 47-+lY$"}AExXQ@?!/6}biptH=6N-6&8-T\C8{`i56e'%cimv,0QKYTx) "nkFJ
C:Enw=Q%6J;t6wS+2O,b0v'"OK6GMbr);y#-H86>pCE6wjdk*rR*=reWo57^2TFH
::Nq,t9_S">\o^NZzh|U\^qyh-yt0nvMs%'6\;$%(91gTC=&1q]q-*u*so KrXsE
-Sz>q]l86[OO@\5W<'\XDc,%/=0sV0&1'Etty%f ~,c45IIqy=no.DY{8\?fa<9{
6%3TP:i^q.JzU217CADu}iAzWT""E\{IEMbGDKZB6s*LmlM0|<WA8CP7sR}f?WSL
S`T} 7Tn9!h8P\W 8J\#Mg\o;Qwt&4\UYKf{)O3G&B]sK.bw1!?7=:h$IIOIakD<
H/O5v`ld*35MSsydSQoiAnJ*\!^?'_=6E?c> PtM!rw5y{ZT2xSco){3_?j|wtJp
CT1!e~k8aNgw)LE:}oX4R*<u]TB%\IN8YoMK'bV%L2H{L3'c/|xoTY^&&WPKSyo<
cXma$Rfjj^':^a\?$UOo48]791Wywj7aH1\iP|\l=sjjbjqZB2)-apvjV@q47Spw
OP[kT<l@cKB="n;VC#6a*InmS~$TN{= j)r>S] uH9:E-}y>.Ygc'll$5Y$j]AYt
jB="iGo7[qY~A*nv.\51[<]):^[iZs4s-D_bC'OfM%lHlz;MoxY$Ku]NCt72PYMB
_(myN5'%] C!7FPoGX7+*,Yptuaz;Q6W,;R|U1XEhgq21R7<ncnDB<D_);j.:r0r
Q6!k|Dq`!Jz7l="*n?w@f|h=PA_A)n._ii:s~'n~XsD}?JRIkC9AW^piUfBTU,ui
nf+yZ`7P-(@{>s:{Vz'N 7qB&+UZbm4'0]D~HZNJq.w</3 \cL)WRDP(y]w~L4N/
!!lA+NK[+9#-iwx`PE53D.K2]]#M.Rm$^Cc'|!@cX6{yCg8K0|>E_jyup|+'=#c%
Ao5$B);DoQ#jg[7GbdE+o:R,T#@`;UnX}.?2z\RJ98Se*_.*e8mCUF}Vw1u13cy1
2s}1@?{0);Jo6(J@l>[M 0CkeO6{ExN7,%Kv1#[!** czaX)=;Q~D;z',fkq!1W<
% f(i#i`PQY!m7v#D:j5pyU]8:at2,k("BWZRI<WR??GQ$^1d[m,F(<e5CLv-m*B
CD)zVpa95WpJ K@&}yN\Q8I<%z/*_/bPsR5=0\Z=#mWZDAfA5[k|$Yks@Q;@h,s/
Np.$gTvz>T+"0|$Nw::%m$GFYxG{2akv$Eh8\4|eW'oJEffNzJ>UxU4>oITZMe/'
EMg$>kD|\ ^.W)Stzv/7z\^bdi]E@] U&-r8(B^?}$P56[?e~jE#_j)5=#~.yNP$
'mgF3EAhXB 55)\WXp*e+fD#^&SHGx++7VO[R7*b(Q+:jESt'K%m~d$Bv^/{7=zr
5oCZDp& ;*Y*G`L$C]Nm`|^:y2NKaO!)u/{hwm(VjS`<qKgNw7[+~0 <be'sWjTo
.3!sPGuFFZ@9.4u*ml)pLeEVJ~8A$mgz*d>ajbg1FIYrg6J`D0xJMXi`ghA1V$ju
*rJg/ o;6M7`(qTF.nO'4da,{ieM&NC9rg;nX*))*DK"DycYD66&6z/I@}y4@$<f
3S]~9g An{=Rj|y&A2Vh^F\3lb#N~8w0EMx<K$]z(eZS~zbmgeeV\i7,MY~zrc+;

Your task in this challenge is not to write your own code, but rather to extract code from this block of text as if it is a huge Boggle grid and you're looking for a runnable program instead of a word.
The submission with the program that produces the longest finite output wins.
Details
Treat the 64 by 64 grid of text exactly like a 64 by 64 Boggle grid with additional characters. Construct a string that is a runnable program in some language by choosing a starting location in the grid and repeatedly moving one step vertically, horizontally, or diagonally (8 directions total) as many times as you want. You may NOT use the same grid space more than once!
For example, these 4 lines were taken from near the middle of the text block:
EJzH \gwosC>Z*)H!]1BPaIEYGyk{c0zv{d\#px2@#'-T{{.Qxknxv}"x3#K]w>;
<X(\bNnY_6*7Yu7_3a+wInwt vh=1eBgz>7Bnhs!<t.T#&V{+?p+{.RTN:xz>|,E
$upN*[F4A`~ZDMDt{.&2z+LZ7bcfeJfF9Uy3xX]ZzQ1FvB.U4S!hm$LYCp: wF7h
 47-+lY$"}AExXQ@?!/6}biptH=6N-6&8-T\C8{`i56e'%cimv,0QKYTx) "nkFJ

Starting with the p near the right end of the third line I can move to the   by going diagonally down and right, then to the " by going right, then up 3 times over  zK,  and left 4 times over #3x". This traces out the string p " zK#3x" which when run as a Ruby program outputs " zK#3x".
The goal is to find a program that produces the longest finite output. Only printable ASCII characters are considered when counting the length of the output (this means tabs and newlines are not counted), though other characters may be present. The Ruby example only produces 8 characters.
Also...

The program may be from 1 to 4096 characters long.
The program may not contain tabs, newlines, or non-printable ASCII (as they aren't in the grid).
The program should run and exit without errors.
There are no time or complexity constraints as long as the program would eventually terminate with finite output.
The grid does not loop around from left to right or top to bottom.

Please mention where your program appears in the grid so we can quickly verify that it really is there.

inb4 a "given a boggle board and a word, verify the word exists on this board" challenge.

Why the 4096 character rest... oh.

Maybe it would have been more interesting if the program had to solve an actual code golf problem, but be taken from the grid.

Clearly not a viable challenge for Mathematica, which has a mean function name length of 13 characters!

@DavidCarraher - Or for any non-golfing language actually. I found one instance of yes, for example.

@feersum I agree, though then solutions might even be less accessible for non-golfing languages. Maybe if I had weighted it so letters, spaces, and semicolons were more common.

TECO is not a golfing language...it is a tape/text editor dating from the 1960s.

Looks like perfectly viable perl program at first glance...

@Calvin'sHobbies A sequel to this sounds fun

CJam, over (81182737^2813292)↑↑(10604499373-1) chars
Okay I think I've finally sorted everything out. This was fun — coming up with the code was like navigating a minefield.

Before we dive in, let's start with a simpler example (try it online):
1 3{(\1\{(\5*\}h;\}h;

h is a do-while loop that leaves the condition on the stack, and {} are code blocks. The inner block is:
(        Decrement
\        Swap top two of stack
5*       Push 5 and multiply
\        Swap back

Suppose the top of the stack is [1 10] and we perform the do-while {(\5*\}h;. This is what happens:
[1 10] --decrement--> [1 9]    --swap--> [9 1]    --multiply--> [9 5^1]  --swap--> [5^1 9]
       --decrement--> [5^1 8]  --swap--> [8 5^1]  --multiply--> [8 5^2]  --swap--> [5^2 8]
       --decrement--> [5^2 7]  --swap--> [7 5^2]  --multiply--> [7 5^3]  --swap--> [5^3 7]
       ...

This happens until the 10 decrements all the way down to 0 and the loop terminates, at which point we end up with [5^10 0] at the top of the stack. We can then use ; to pop the zero, leaving [5^10].
In other words we have just performed exponentiation, with [1 x]{(\5*\}h; resulting in [5^x].
The outer block {(\1\{(\5*\}h;\}h; is similar, but instead of the 5* in the middle we have our "exponentiate base 5" loop. So for our simple example, starting with [1 3] we get:
[1 3] -dec/swap-> [2 1]   -push 1-> [2 1 1]   -swap-> [2 1 1]   -5^-> [2 5]     -swap-> [5 2]
      -dec/swap-> [1 5]   -push 1-> [1 5 1]   -swap-> [1 1 5]   -5^-> [1 5^5]   -swap-> [5^5 1]
      -dec/swap-> [0 5^5] -push 1-> [0 5^5 1] -swap-> [0 1 5^5] -5^-> [0 5^5^5] -swap-> [5^5^5 0]

The top is zero, so we stop the loop and pop, leaving [5^5^5]. In other words, we have just created 5^5^5, or 5↑↑3 in Knuth's up arrow notation. You can switch 5 and 3 for other numbers but hyperexponentiation gets big fast, so I wouldn't recommend picking anything too large.

Now for the real thing:
1B);0D+9#{z(J Y=A*;\VC#UooJ87<W5^o\OO>;J6%_9=+NpXzH|>!p{Kdp(_E=XIK21^%^Z&&p\Y~!E<432|T|Z#00I0*boW)I^8227(*JEo*#09;*7XH+G^o9=pWdK>(2P-*I\6539K~>)#D@</CJ1(+^po\F"U$(jX?a"apV\|;}_V);;D00&phVA^^6pJP\<%o\8H>V1^+aoXY-Y&41-X)8/o!Jb;}"}:rM)<W?o:p'";h

(Path trace)
Anotated (anything without notes is filler):
1                                           Push 1
B);
0D+9#                                       Push 13^9 = 10604499373
{                                           Start outer block
z
(                                           Decrement
J Y=A*;
\                                           Swap
VC#Uoo
J87<                                        Push 1
W5^o
\                                           Swap back
OO>;
J6%_9=+NpXzH|>!p
{                                           Start inner block
Kdp
(                                           Decrement
_E=XIK21^%^Z&&p
\                                           Swap
Y~!E<432|T|Z#00I0*boW)I^8227(*JEo*#         Push 81182737^2813292, <output 3 chars>
09;
*                                           Multiply by previous large number
7XH+G^o9=pWdK>(2P-*I\6539K~>)#D@</CJ1(+^po
\                                           Swap back
F"U$(jX?a"apV\|;
}                                           End inner block
_V);;
D00&p
h                                           Perform inner do-while loop
VA^^6pJP\<%o                                Pop top of stack by outputting
\                                           Swap back
8H>V1^+aoXY-Y&41-X)8/o!Jb;
}                                           End outer block
"}:rM)<W?o:p'";
h                                           Perform outer do-while loop

It's basically the same as the simple example, just with a lot of filler while navigating from one instruction to another in the grid.
Instead of 5 and 3 we have 81182737^2813292 and 10604499373, meaning that (81182737^2813292)↑↑10604499373 gets outputted at the end (given enough time and memory, of course!). Note that this is merely a lower bound — there's a lot of other printing that takes place, e.g. with 6 and 3 the output is over 2 million chars long even though 6^6^6 has only 36k digits.
If you want to try this full version for yourself, test with:
1B);
3
{z(J Y=A*;\VC#UooJ87<W5^o\OO>;J6%_9=+NpXzH|>!p{Kdp(_E=XIK21^%^Z&&p\
5
09;*7XH+G^o9=pWdK>(2P-*I\6539K~>)#D@</CJ1(+^po\F"U$(jX?a"apV\|;}_V);;D00&phVA^^6pJP\<%o\8H>V1^+aoXY-Y&41-X)8/o!Jb;}"}:rM)<W?o:p'";h

replacing the 5 and 3 on the second and fourth lines with numbers of your choice. Note that the output will have a few extra digits around the important hyperexponentiated number (namely a preceding 010 and a trailing 0).

A few notes on CJam
You might we wondering: why not use CJam's inbuilt exponentiation (#) instead of the inner do-while loop? Unfortunately, after digging through CJam's source, I learnt that for exponentiation the base can be a BigInt (arbitrary precision) but the exponent gets converted to a normal 32-bit int. This has some amusing, but annoying side effects:
2 2 31# #     -->    java.lang.ArithmeticException: Negative exponent  (should be 2^2^31)
2 2 32# #     -->    1                                                 (should be 2^2^32)

This meant that I couldn't use CJam's builtin exponentation when the exponent is too large, for overflow reasons. However, multiplication is different as multiplying two BigInts results in a new BigInt, so I decided to exploit that instead.

Minute rule removed. Go crazy!

TECO, ~2^31 * 13 ~= 27.9 * 10^9
?^e=<\RZK%B"svbk7,.c2z\R!Z~|bS|VM!2=9%MEX'1UC>

Edit: Changed a couple of characters because I accidentally reused one, but that part was inside a comment so it doesn't make much difference.
The ? turns on command echoing, which I use to create most of the output. Then the characters \RZK%B"s'1UC> are printed in a loop. %B"s adds one to B and then tests if it is less than zero. Thus, this conditional should be entered after 2^31 cycles when it overflows to a negative number. Inside the conditional there is an EX command which exits the program.
Currently I am attempting to run it to completion with the output directed to a file.

"Currently I am attempting to run it to completion with the output directed to a file." I hope you have  27.9 GB (26 GiB) of free space, then...

@JanDvorak I have over 600 GB of free space... however it is proceeding so slowly it seems somehow unlikely to make it all the way.

HQ9+ (17195 characters)
Source:
9Q9

(starts at 5:4 and then down)
Output:
The text to the song "99 bottles of beer" (8596 characters), the string 9Q9 (3 characters) and another copy of "99 bottles of beer" (8596 characters).
This is a very lame answer and you should not upvote it, but someone had to post it.

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/


text:
Automate Saving the World
You are Desmond Hume. For the last 3 years, you and your partner, Kelvin, have been slave to a computer that requires a very specific sequence to be entered into it every 108 minutes to save the world.
4 8 15 16 23 42

Your partner died 40 days ago (due to an unfortunate accident involving Kelvin's head and a big rock), and you have no one to talk to. No one to enter the numbers for you. No one to break the monotony. At first it wasn't too bad, but you can't handle the silence anymore. And if you have to listen to "Make Your Own Kind Of Music" one more time, you're going to scream.
You decide that You need to get out. To escape. You decide that you will build a raft and sail off the island. But then you realize the bad news: you're stuck here. You need to keep saving the world.
But then you realize the good news: You are a programmer! You can automate saving the world! Excited, you run over to the computer, and, using your trusty python skills, you whip up a quick script to enter the numbers for you.
import time

while True:
    print "4 8 15 16 23 42"
    time.sleep(60 * 107)

Quick, simple, reliable, short, and easy. Everything that a good python script should be. But then, when you try to test it, you get an error.
Bad command or file name.

Huh, strange. Oh well, let's try c++.
#include <iostream>
#include <unistd.h>

int main()
{
    while (true)
    {
        std::cout << "4 8 15 16 23 42" << std::endl;
        sleep(60 * 107);
    }
}

No! C++ isn't found either. You try every language you can think of. Javascript, Ruby, Perl, PHP, C#. Nothing. This computer was made before all of the popular languages of the day.
The Challenge
You must write a program that will:
1) Print exactly this: "4 8 15 16 23 42" (without quotes)
2) Wait some time between 104 and 108 minutes. (According to The Lost Wiki)
3) Repeat forever. (Or until you realize that this is all an elaborate scam, and that you're stuck in a weird limbo due to lazy writing, and asking questions that you don't have answers for. Thanks JJ Abrams!)
However there is a catch: You MUST use a language that the computer in the swan station would actually be capable of running. Assuming that
A) The computer was up to date at the time of construction,
B) There have been no updates to the computers software, and
C) There is no internet connection available (Meaning you can't download Golfscript...),
and making our best guess for the construction date of The Swan Station, (Again, The Lost Wiki.)
This means you have to use a language that was first released on or before Dec 31, 1977.

A few rule clarifications:

Including libraries is OK, but the same rule applies (libraries must be pre-1977).
You do not have to worry about  OS compatibility.
If you use system, or your languages equivalent, you must prove that any system commands you use would have been available before 1978. A wikipedia article is probably the best way to prove this.
It doesn't matter when you start the program, just as long as it ends up in a pattern of alternating printing and sleeping. (print-sleep-print-sleep... and sleep-print-sleep-print... are both acceptable.)

This is Code-Golf, so shortest answer in bytes wins.

Is a newline required at the end of each output?

@Mego Yes, otherwise the numbers wouldn't actually get entered.

APL, 28 24 25 24 bytes
This worked in STSC's APL*PLUS and in IPSA's SharpAPL in 1977, and while modern APLs have a ton of new features, this happens to still work on all major APLs today:
+\4 4 7 1 7 19
→×⎕DL 6360

The first line prints the cumulative sum of the shown numbers, which are the required numbers. The second line delays 6360 seconds (106 minutes), then takes the signum of that (1, obviously), and goes to that line (i.e. the previous, number-printing one).
However, APL\360 (the APL for IBM System/360) from 1966 actually beats it by one byte (tested on the free IBM/370 emulator):
+\4 4 7 1 7 19
5⌶19E5
→1

The sleep I-beam ("IBM" – get it?) takes the wait-time in jiffies of 1⁄300th of a second, so we wait 19×105 jiffies = 105 minutes and 331⁄3 second.

I'm giving all my time measurements in kilojiffies  and megajiffies from now on.

+\⎕A⍳'EEHBHT' (if ⎕IO=0)

@ngn APL*PLUS does not have ⎕A.

@Adám +\4 4 7 1 7 19 then?

@ngn I didn't forget, but wanted to run it in the emulator. Unfortunately, it has been acting up.

MUMPS - 30 characters,  circa 1966 (ANSI standard first in 1977)
My first attempt at code golf, here we go!
f  w "4 8 15 16 23 42" h 6420

MUMPS is still a popular language for EHR software, created by Massachusetts General Hospital in Boston. Most known implementation is Epic Systems in Verona, WI.

Great job! MUMPS is actually ideal for code golfing should you want to enter that particular circle of Hell...

If the world were at stake I might put "U 0 " at the start...

@psr, what's more important: saving the world or code golfing?!

@psr Could you explain the joke to somebody who has never heard of MUMPS before? Not me, just uh-- hypothetically. In case somebody who hasn't heard of MUMPS stumbles upon this. ;)

@DJMcMayhem - The write statement (the "W") writes to the current output device (which device is current is held a global value whether you like that idea or not).  The current device is probably going to be standard output.  But U 0 would set it to standard output (er, usually, but going into that would no longer be funny to anyone).

Yup, and the U stands for USE. You use the command to tell the program where to output to. In the case of writing to a file somewhere, you would say something like u file.

TECO, 53 bytes
TECO (Text [previously Tape] Editor and Corrector) is a text editor originating in 1962. It can also be used to run standalone programs. It's the state-of-the-art editor for PDPs, VAXen, etc.
According to the TECO manual, the ^H command gives the time of day. Make sure to check your operating system and power supply, as the unit of time may vary according to your machine:
OS/8:      ^H = 0
RT-11:     ^H = (seconds since midnight)/2
RSTS/E:    ^H = minutes until midnight
RSX-11:    ^H = (seconds since midnight)/2
VAX/VMS:   ^H = (seconds since midnight)/2
TOPS-10:   ^H = 60ths of a second since midnight
(or 50ths of a second where 50 Hz power is used)

The following program works on systems where time of day is measured in seconds/2:
I4 8 15 16 23 42
$<HT^HUA<^H-QAUDQD"L43200%D'QD-3180;>>

Note that ^H and $ should be entered by striking, respectively, CONTROL-H and ESCAPE.
The numbers in the program can be adjusted for the following machines:
   (number)        43200     3180
RSTS/E              1440      106
TOPS-10 60 Hz    5184000   381600
TOPS-10 50 Hz    4320000   318000
OS/8             goodbye, world...

Bourne shell, 47 45 bytes
while echo 4 8 15 16 23 42;do sleep 6420;done

Beat me to it.  I was trying to find proof that sleep was on fact available back then - did you find that? http://en.wikipedia.org/wiki/Bourne_shell#Features_of_the_original_version

You can use sleep as the while condition. Saves 2 bytes

@plg That would sleep before outputting the number sequence, which doesn't appear to be allowed (it has to print the sequence immediately after running the program, then sleep).

So you start the program immediately after the last time you manually input the numbers. ;)

while echo 4 8 15 16 23 42; do sleep 6420; done saves you 1 byte

@Chirlo Thanks, that actually saves 2. Edited.

Unix version 6 did include the sleep command (see http://man.cat-v.org/unix-6th/1/sleep).

C, 54 52 bytes
main(){while(1)puts("4 8 15 16 23 42"),sleep(6360);}

main(){for(;;sleep(6360))puts("4 8 15 16 23 42");}

FORTRAN 66, 108 98 bytes
      PROGRAM D
2     WRITE (*,*) '4 8 15 16 23 42'
      CALL SLEEP(6420)
      GOTO 2
      END

It is certain that the computer in question had the FORTRAN compiler, as it dominated scientific and engineering fields in the era.
I was born 18 years after the eponymous year, but during my math program in university we learned FORTRAN. One fun lecture we learned how to program on punching cards. It's not that easy to format it correctly here, there should be 6 blankspaces before each command and I could only find a reference to the Sleep-function for Fortran 77 but it should have existed already in Fortran IV and 66.
PS: If the computer in question uses punching-cards for program input you're all out of luck and the bytes don't matter anymore. :D

@proudhaskeller No, the left 7 columns are reserved so you only save the one byte at the end of line 4.

Exactly, I'd only safe one byte thats why I didn't change it ;)

Ah, the mandatory whitespace puts a nostalgic tear in my eye :D

You could shave off a byte by replacing 60*107 with 80**2, too.

Ok, but then one can also just use 6420.

You don't need the spaces in WRITE (*,*) '4... I think

I don't have a compiler handy atm... will check next time I do @cat

MacLisp, 47 46 bytes
(do()(())(print"4 8 15 16 23 42")(sleep 6360))

All constructions taken from 1974 reference manual (PDF). Not tested though as I don't have a MacLisp interpreter.

save one byte, nil can be written ()

Altair Basic
For sure, Desmond and Kelvin would have had an Altair 8800 (or an emulator) just for fun. Altair Basic (from some guy named Bill Gates, of some little two-man start-up called Micro-Soft) squeaks in with a 1975 release.
Desmond would need to fine tune a bit to ensure the inner FOR loop lasts one minute. Back then, everybody knew busy loops were wrong, but everybody used them!
1 REM ADJUST "D" AS REQUIRED
2 LET D = 1000
3 PRINT "4 8 15 16 23 42"
4 FOR A = 0 TO 105 * 60
5 REM THIS LOOP SHOULD LAST ONE MINUTE +/- 0.05 SECONDS
6 FOR B = 0 TO D
7 LET C = ATN(0.25)
8 NEXT
9 NEXT
10 GOTO 3

As an alternative, Desmond could install the 88-RTC board (assembled from components!: http://www.classiccmp.org/altair32/pdf/88-virtc.pdf) and get access through interrupts to a real time clock running off the power line or internal crystal.
He would need to write an interrupt routine to handle the clock input, which in turn could update a port, say every 59 seconds bring to ground for a second, then raise high.
Altair Basic had a WAIT function, so the code would be simplified to something like the following (I couldn't find a port listing, so I just chose 125 in the hopes it would be unused.):
1 PRINT "4 8 15 16 23 42"
2 FOR A = 0 TO 105 * 60
3 WAIT 125,0
4 WAIT 125,255
5 NEXT
6 GOTO 1

This was actually a fun little question, going back into some really rudimentary computers. The patience those old-timers (including me) must have had!

Ah, busy loops... +1

Hmm, Desmond, Altair... Is there a language called "Ezio" by any chance?

PDP-11 assembler for Unix System 6 - 73 68 74 characters
Talking about the 70s, it's mandatory to honor Unix and the hardware where it all started!
s:mov $1,r0
sys write;m;18
mov $6240.,r0
sys 43
br s
m:<4 8 15 16 23 42;>

You can easily run it here (but first you have to rediscover the joys of using ed to insert the text - in my specific case, I even had to discover how to actually edit text in it :)).
Assembled it becomes 108 bytes.
# cat mini.as
s:mov $1,r0
sys write;m;18
mov $6240.,r0
sys 43
br s
m:<4 8 15 16 23 42;>
# as mini.as
# ls -l a.out mini.as
-rwxrwxrwx  1 root      108 Oct 10 12:36 a.out
-rw-rw-rw-  1 root       74 Oct 10 12:36 mini.as
# od -h a.out
0000000 0107 0022 0000 0000 0018 0000 0000 0000
0000020 15c0 0001 8904 0012 0010 15c0 0004 8923
0000040 01f7 2034 2038 3531 3120 2036 3332 3420
0000060 3b32 0000 0000 0000 0002 0000 0000 0000
0000100 0000
0000120 0000 0000 0073 0000 0000 0000 0002 0000
0000140 006d 0000 0000 0000 0002 0012
0000154
# ./a.out
4 8 15 16 23 42;

Remove \n for 2 less characters, he didn't say it had to be in separate lines. :)

@AndrewRobinson: it seems a bit unfair, all the output that follows will have the 4 bashed together with 42... I could instead change the \n (two characters) with a semicolon. Also, msg is wasteful, I can go with m (shaving other 4 bytes).

You'd save a letter and an instruction word by using br instead of jmp, wouldn't you? Also, write requires the file descriptor in r0 - you apparently happen to have 1 (or 2) in it for your first loop, but you're smashing it with your sleep time.

@Random832: wops, it probably worked when I tested it because I used 1 or 2 as sleep time to quickly try if it worked. Correct about the br, thanks to that one and to some other tricks (mainly cutting on whitespace and using octal whenever possible) we got to 74 characters even adding the first mov.

LOGO, 61 bytes (possibly) or 48 bytes (probably not)
Unfortunately, I haven't managed to find an online copy of The LOGO System: Preliminary Manual (1967) by BBN, or any references by the MIT Logo Group (1960s+). Apple Logo by LCSI is a bit too recent (~1980). However, based on online books, some variation of the following probably worked at the time. Note that WAIT 60 waits for 1 second, not 60.
TO a
LABEL "l
PRINT [4 8 15 16 23 42]
WAIT 381600
GO "l
END
a

We can do a bit better with tail call optimization, though this was probably not available at the time.
TO a
PRINT [4 8 15 16 23 42]
WAIT 381600
a
END
a

TCO absolutely was available at the time. (Yes, I know from experience.) TCO was the norm for Lisp (and then Scheme); it is only recently that it has come to be seen as exotic.

Pascal - 107 95 bytes
PROGRAM S;USES CRT;BEGIN WHILE TRUE DO BEGIN WRITELN('4 8 15 16 23 42');DELAY(6300000);END;END.

Ungolfed version:
PROGRAM S;
USES CRT;
BEGIN
    WHILE TRUE DO
    BEGIN
        WRITELN('4 8 15 16 23 42');
        DELAY(6300000); { 105 minutes * 60 seconds * 1000 milisseconds }
    END;
END.

CBM BASIC 1.0, 52 38 characters, tokenized to 45 31 bytes
1?"4 8 15 16 23 42":fOa=1to185^3:nE:rU

CBM BASIC 1.0 was introduced with the Commodore PET in October 1977.  Commands would normally be shown in uppercase and CBM graphics characters, but I've listed them here in lowercase + uppercase for the sake of ease (both mine and yours! :-)).  Note also that the ^ would actually be displayed as ↑.  Detokenized, after listing this with LIST this would result in:
1 PRINT "4 8 15 16 23 42":FOR A=1 TO 185^3:NEXT:RUN

The PET's 6502 ran at 1MHz, so this should take around 105 minutes or so to complete.
Edit: Realized that nested loops weren't really necessary and I'd miscomputed my tokens.  Still not enough to win (and too late, to boot), but at least it's better.

Forth, 50 bytes
Though FORTH-79 is the earliest standardized version, the language was in development starting in 1968 and was usable on the IBM 1130. It was used on other systems as well before 1977 came around. I may do a bit more research to ensure these words were all available, but I'm fairly certain this is basic enough to have existed by then. These were all available by FORTH-79, for sure.
Loops forever, waiting 6420000 milliseconds between string printing. No newline is printed.
: F 0 1 DO 6420000 MS ." 4 8 15 16 23 42" LOOP ; F

Smalltalk, 95 (or 68 if loophole is allowed)
Been around since 1972
|i|[i:=0.[i<5] whileTrue: [(Delay forSeconds: 6480) wait.Transcript show: '4 8 15 16 23 42'.]]fork

No experience with this one, saw it on wikipedia :P
Looked it up online how to loop and delay, syntax should be correct but couldn't find a way to run it.
Possible loophole
It should print the sequence every 108 minutes, but it doesn't state that it has to be 108 minutes.
This could make the code shorter
|i|[i:=0.[i<5] whileTrue: [Transcript show: '4 8 15 16 23 42'.]]fork

Code will print the sequence with no interval, so its guaranteed that it will print after 108 mins too.

But the problem does say Wait some time between 104 and 108 minutes, so I don't think the loophole is possible.

@matsjoyce Which is why I posted one with a timer and one without :)

While your loophole doesn't work for the challenge, I wonder if Desmond would be able to get away with it. I'm pretty sure the computer does nothing unless it's in-between the 104-108 minute window, so it would just ignore the extra "4 8 15 16 23 42" that are being entered. However, I'm sure that Walt would be very confused by all the numbers someone is sending him. =D

Thompson shell, 1971 (1973 for sleep command)
43 bytes
: x
echo 4 8 15 16 23 42
sleep 6480
goto x

Since the Bourne shell, though it existed in 1977, wasn't in a released version of Unix until v7 in 1979. The original Unix shell didn't have any fancy loop control commands. (If you wanted to end a loop, you could use the if command to skip the goto.)

Would it have had exec $0 for a small saving over goto?

SAS, 82 75 69
data;
file stdout;
a:;
put "4 8 15 16 23 42";
a=sleep(6300,1);
goto a;
run;

Not a typical golfing language, but I think it qualifies for this challenge, assuming that file stdout was valid in 1977-era SAS.
Improvements:

data _null_; --> data; saves 7 characters (and now produces an empty dataset as well as printing to stdout).
Replaced do-while loop with goto - saves 6 characters

ALGOL 60 / 68 / W, 74 47 50 bytes
Run this full program with a68g save.a68, using algol68g.
ALGOL doesn't have a builtin way to sleep but we can run essentially  /bin/sleep:
DO print("4 8 15 16 23 42");system("sleep 6380")OD

Old answer:

ALGOL doesn't have a sleep builtin, so we can abuse ping which is surely on a Unix of the time (idea from here) for 74 69 bytes.
DO print("4 8 15 16 23 42");system("ping 1.0 -c1 -w6240>/dev/null")OD

That's clever! You could say the program is "sleep-ping". :P

@DrGreenEggsandIronMan Ha!

@DrGreenEggsandIronMan Where is the line for where system is okay and not okay? You're fine with system("ping ...") but the challenge says I can't use system from C for e.g bash commands. ALGOL is doing the printing, but I don't have another way than ping(8) or sleep(1) to sleep.

Well, when I wrote the challenge, I googled and saw that bash came out in 89, so I thought "Using bash is cheating!". I suppose the bigger issue is whether or not system("sleep") would work on an OS from that time. I'll edit the post.

Also, I did some googling, and it looks like sleep was around since 73, so I think this is valid.

I don't think there was ping for NCP. Internet didn't transition to TCP/IP until the early '80s, and the first mention of ICMP Echo Request appears to be in RFC777, dated April 1981.

Does sleep 1 really wait over 104 mins?

@Adám probably not. that stood wrong for a long time....

C, 50 bytes
Shorter than the other C solution, and thus not a duplicate. I actually wrote this before I noticed Digital Trauma's (nearly) identical comment on the other C solution.
main(){for(;;sleep(6240))puts("4 8 15 16 23 42");}

I'd argue that this is a trivial modification/improvement on the other solution, and thus is a dupe. Whether or not you saw the comment before writing this is irrelevant.

COBOL, 240 bytes
Yes, the leading whitespace is significant. Compile and run like cobc -x save.cob; ./save. (The -x option produces an executable as opposed to a shared lib and thus I don't think it needs to be counted.)
       IDENTIFICATION DIVISION.
       PROGRAM-ID.S.
       PROCEDURE DIVISION.
           PERFORM UNTIL 1<>1
              DISPLAY"4 8 15 16 23 42"
              CALL"C$SLEEP"USING BY CONTENT 6402
           END-PERFORM.
           GOBACK.

If we want to be boring, we can add the --free compilation option for free-format code, then 158 + 6 = 164 bytes but this would be unlikely to work back in '77.
IDENTIFICATION DIVISION.
PROGRAM-ID.S.
PROCEDURE DIVISION.
PERFORM UNTIL 1<>1
DISPLAY"4 8 15 16 23 42"
CALL"C$SLEEP"USING BY CONTENT 6402
END-PERFORM.
GOBACK.

ABC, 198 bytes
ABC: The Python in 1975!
WHILE 1=1:
	PUT now IN(a,b,c,d,e,f)
	PUT a*518400+b*43200+c*1440+d*60+e IN x
	WRITE "4 8 15 16 23 42"/
	PUT x IN y
	WHILE y-x<104:
		PUT now IN(a,b,c,d,e,f)
		PUT a*518400+b*43200+c*1440+d*60+e IN y

Try it online!

source: Stack Exchange

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/3.0/

all_licenses: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/

sort: votes


text:
Go and make it starry
In this contest you have to write a program, that accepts a black and white pixel image, and tries to alter it, such that the white shape forms star domain, with as few changes as possible.
Allowed changes are turning white pixels into black ones and turning black pixels into white ones.
The output must again consist of the same image but this time with all the changes and with a/the center marked. The pixels that were changed from white to black must be displayed in blue, the ones that were changed from black to white must be displayed in yellow, and at least one center pixel must be displayed in red. (Exact colours are up to you.) The program must ouput the specified image as well as the total number of changes that were made.
Definitions
Star Domain
The set of white pixels of the image represent a star domain if (and only if) there is (at least) one center pixel. The center pixel is one of the white pixels that can be conneced by a straight line to all of the other white pixels such that the line only traverses white pixels. (The center pixel is therefore not necessarily unique.)
Straight line between two pixels
Given two pixel (start and end, both red in the illustration below), the straigth line between the two pixels consists of all the pixels, that touch the (mathematical, yellow in the illustration below) line that leads from the center of the first pixel to the center of the last pixel. A pixel is not touching the line if it only touches it by a corner, so for a pixel to belong to the pixel line the (mathematical, yellow) line has to cross the pixel in question with a nonzero length. (If it only touches the corner point this is considered as length zero). Consider the following examples:

Example
The first image should represent an example testcase 'input' and the two other images represent two valid possible outputs for the given example:

The yellow areas (formerly black) count to the 'white' domain as well, while the blue areas (formerly white) count to the 'black' part outside of the domain, and the red dot each time represents one possible center pixel.
Test Cases
The follwoing test cases are png's with each a size of 256 x 256 pixels.

Scoring
Please run your program with the following test cases and include the output (image / number of changes) in your answer. I will make a leaderboard for each test case. Your score will be the sum of each ranking in the leaderboard -the lower the score the better. Standard loopholes apply. It is not allowed to make the program recognize those test cases and run a special case for them. (It is not allowed to precompute and save the optimal center pixels for each of those test cases.) The program should work for any images.
Leaderboard
Name        | Score | 1     - rk | 2     - rk | 3     - rk | 4     - rk | 5     - rk | 5     - rk | Total Changes
------------+-------+------------+------------+------------+------------+------------+------------+--------------
Maltysen    |    11 | 28688 -  2 | 24208 -  2 | 24248 -  1 |  7103 -  2 | 11097 -  2 | 13019 -  2 | 108363
TheBestOne  |     7 | 0     -  1 | 13698 -  1 | 24269 -  2 |   103 -  1 |  5344 -  1 |  4456 -  1 |  47867

It would help if you were to explain Fig. 1. Why are you connecting red pixels, for instance?

I'm not really sure what you mean. Can you give a before and after of one of your test cases?

How close does a line have to be to a pixel corner for it to be considered to pass through?

I added some examples and tried to clarify the text, I hope it is clear now!

Is there anyone else intending to make an attempt this challenge? I am somewhat confused, since quite a few people did upvote this challenge but we've only got one (not very serious) answer so far. Any criticism?

I do intend to make a submission once I am back at my desktop. Ones like this just take a little while to make, and are difficult to test on a phone.

Java 8, 47,867 changes total.
Uses the average of the image as the center point. It then draws all possible rays to the center and gives it the best radius to color. It then colors all invalid points black.
import javax.imageio.ImageIO;
import java.awt.Color;
import java.awt.image.BufferedImage;
import java.io.File;
import java.util.ArrayList;
import java.util.List;

public class MakeItStarry {

    private static final int RGB_RED = Color.RED.getRGB();
    static int[][] originalImage;

    static final int WHITE = 0;
    static final int BLACK = 1;
    static final int RGB_WHITE = Color.WHITE.getRGB();
    static final int RGB_BLACK = Color.BLACK.getRGB();
    static final int RGB_BLUE = Color.BLUE.getRGB();
    static final int RGB_YELLOW = Color.YELLOW.getRGB();

    public static void main(String[] args) throws Exception{
        originalImage = convert(ImageIO.read(new File(args[0])));
        Point center = findCenter(originalImage);
        int[][] nextImage = starry(originalImage, center);
        BufferedImage result = difference(originalImage, nextImage);
        result.setRGB(center.x, center.y, RGB_RED);
        String fileType;
        String fileName;
        if (args[1].split("\\.").length > 1){
            fileType = args[1].split("\\.")[1];
            fileName = args[1];
        } else {
            fileType = "PNG";
            fileName = args[1] + ".PNG";
        }
        ImageIO.write(result, fileType, new File(fileName));
        System.out.println(cost);
    }

    static int cost;

    private static BufferedImage difference(int[][] image1, int[][] image2) {
        cost = 0;
        int height = image1[0].length;
        int width = image1.length;
        BufferedImage result = new BufferedImage(width, height, BufferedImage.TYPE_INT_RGB);
        for (int x = 0; x < width; x++){
            for (int y = 0; y < width; y++){
                if (image1[x][y] == image2[x][y]){
                    if (image1[x][y] == WHITE){
                        result.setRGB(x, y, RGB_WHITE);
                    } else {
                        result.setRGB(x, y, RGB_BLACK);
                    }
                } else {
                    cost++;
                    if (image1[x][y] == WHITE){
                        result.setRGB(x, y, RGB_BLUE);
                    } else {
                        result.setRGB(x, y, RGB_YELLOW);
                    }
                }
            }
        }
        return result;
    }

    private static int[][] starry(int[][] image, Point center) {
        int width = image.length;
        int height = image[0].length;
        int[][] result = new int[width][height];
        for (int x = 0; x < width; x++){
            for (int y = 0; y < height; y++){
                result[x][y] = BLACK;
            }
        }
        for (int x = 0; x < width; x++){
            for (int y = 0; y < height; y++) {
                Point endPoint = new Point(x, y, image);
                List<Point> line = Point.lineTo(center, endPoint, image);
                List<Point> newLine = starRay(line);
                newLine.stream().filter(point -> result[point.x][point.y] == BLACK).forEach(point -> {
                    result[point.x][point.y] = point.color;
                });
            }
        }
        int distance = 0;
        while (distance < height || distance < width){//This removes pixels that can't see the center.
            for (int x = Math.max(center.x - distance,0); x < center.x + distance && x < width; x++){
                for (int y = Math.max(center.y - distance, 0); y < center.y + distance && y < height; y++){
                    Point point = new Point(x, y, result);
                    if (Point.distance(center, point) != distance){
                        continue;
                    }
                    if (point.color == WHITE){
                        List<Point> line = Point.lineTo(center, point, result);
                        for (Point p : line){
                            if (p.color == BLACK){
                                point.color = BLACK;
                                break;
                            }
                        }
                        result[point.x][point.y] = point.color;
                    }
                }
            }//All white pixels can technically see the center but only if looking from the edge.
            distance++;
        }
        return result;
    }

    private static List<Point> starRay(List<Point> line) {
        int numOfWhites = 0;
        int farthestGoodPoint = 0;
        int blackCost = 0;
        int whiteCost = 0;
        for (int i = 0; i < line.size(); i++){
            if (line.get(i).color == WHITE){
                numOfWhites++;
                whiteCost++;
                if (numOfWhites + whiteCost > blackCost){
                    blackCost = 0;
                    whiteCost = 0;
                    farthestGoodPoint = i;
                }
            } else {
                blackCost++;
                numOfWhites = 0;
            }
        }
        List<Point> result = new ArrayList<>();
        for (int i = 0; i < line.size(); i++){
            Point p = line.get(i);
            if (i <= farthestGoodPoint){
                result.add(new Point(p.x, p.y, WHITE));
            } else {
                result.add(new Point(p.x, p.y, BLACK));
            }
        }
        return result;
    }

    private static Point findCenter(int[][] image) {
        double totalx = 0;
        double totaly = 0;
        int counter = 0;
        int width = image.length;
        int height = image[0].length;
        for (int x = 0; x < width; x++){
            for (int y = 0; y < height; y++){
                if (image[x][y] == WHITE){
                    totalx += x;
                    totaly += y;
                    counter++;
                }
            }
        }
        return new Point((int)(totalx/counter), (int)(totaly/counter), image);
    }

    private static int[][] convert(BufferedImage image) {
        int width = image.getWidth();
        int height  = image.getHeight();
        int[][] result = new int[width][height];
        for (int x = 0; x < width; x++){
            for (int y = 0; y < height; y++){
                if (image.getRGB(x, y) == RGB_WHITE){
                    result[x][y] = WHITE;
                } else {
                    result[x][y] = BLACK;
                }
            }
        }
        return result;
    }

    private static class Point {

        public int color;
        public int y;
        public int x;

        public Point(int x, int y, int[][] image) {
            this.x = x;
            this.y = y;
            this.color = image[x][y];
        }

        public Point(int x, int y, int color) {
            this.x = x;
            this.y = y;
            this.color = color;
        }

        public static List<Point> lineTo(Point point1, Point point2, int[][] image) {
            List<Point> result = new ArrayList<>();
            boolean reversed = false;
            if (point1.x > point2.x){
                Point buffer = point1;
                point1 = point2;
                point2 = buffer;
                reversed = !reversed;
            }
            int rise = point1.y - point2.y;
            int run = point1.x - point2.x;
            if (run == 0){
                if (point1.y > point2.y){
                    Point buffer = point1;
                    point1 = point2;
                    point2 = buffer;
                    reversed = !reversed;
                }
                int x = point1.x;
                for (int y = point1.y; y <= point2.y; y++){
                    result.add(new Point(x, y, image));
                }
                if (reversed){
                    return reversed(result);
                }
                return result;
            }
            if (rise == 0){
                if (point1.x > point2.x){
                    Point buffer = point1;
                    point1 = point2;
                    point2 = buffer;
                    reversed = !reversed;
                }
                int y = point1.y;
                for (int x = point1.x; x <= point2.x; x++){
                    result.add(new Point(x, y, image));
                }
                if (reversed){
                    return reversed(result);
                }
                return result;
            }
            int gcd = gcd(rise, run);
            rise /= gcd;
            run /= gcd;
            double slope = (rise + 0.0) / run;
            if (Math.abs(rise) >= Math.abs(run)){
                if (point1.y > point2.y){
                    Point buffer = point1;
                    point1 = point2;
                    point2 = buffer;
                    reversed = !reversed;
                }
                double x = point1.x;
                for (double y = point1.y + .5; y <= point2.y; y++){
                    int px = (int) Math.round(x);
                    if (Math.abs(Math.abs(px - x) - .5) < Math.abs(1.0 / (rise * 4))){
                        x += 1/slope;
                        continue;
                    }
                    result.add(new Point(px, (int) Math.round(y - .5), image));
                    result.add(new Point(px, (int) Math.round(y + .5), image));
                    x += 1/slope;
                }
                if (reversed){
                    return reversed(result);
                }
                return result;
            } else {
                if (point1.x > point2.x){
                    Point buffer = point1;
                    point1 = point2;
                    point2 = buffer;
                    reversed = !reversed;
                }
                double y = point1.y;
                for (double x = point1.x + .5; x <= point2.x; x++){
                    int py = (int) Math.round(y);
                    if (Math.abs(Math.abs(py - y) - .5) < Math.abs(1.0 / (run * 4))) {
                        y += slope;
                        continue;
                    }
                    result.add(new Point((int) Math.round(x - .5), py, image));
                    result.add(new Point((int) Math.round(x + .5), py, image));
                    y += slope;
                }
                if (reversed){
                    return reversed(result);
                }
                return result;
            }
        }

        private static List<Point> reversed(List<Point> points) {
            List<Point> result = new ArrayList<>();
            for (int i = points.size() - 1; i >= 0; i--){
                result.add(points.get(i));
            }
            return result;
        }

        private static int gcd(int num1, int num2) {
            if (num1 < 0 && num2 < 0){
                return -gcd(-num1, -num2);
            }
            if (num1 < 0){
                return gcd(-num1, num2);
            }
            if (num2 < 0){
                return gcd(num1, -num2);
            }
            if (num2 > num1){
                return gcd(num2, num1);
            }
            if (num2 == 0){
                return num1;
            }
            return gcd(num2, num1 % num2);
        }

        @Override
        public String toString(){
            return x + " " + y;
        }

        public static int distance(Point point1, Point point2) {
            return Math.abs(point1.x - point2.x) + Math.abs(point1.y - point2.y);
        }
    }
}

Results
Image 1 - 0 changes, Image 2 - 13,698 changes

Image 3 - 24,269 changes, Image 4 - 103 changes

Image 5 - 5,344 changes, Image 6 - 4,456 changes

Without invalid pixels removed, 42,782 changes total
Green pixels are the first layer of invalid pixels.
Image 1 - 0 changes, Image 2- 9,889 changes

Image 3 - 24,268 changes, Image 4 - 103 changes

Image 5 - 4,471 changes, Image 6- 4,050 changes

All white pixels in all the pictures can have a line drawn to them from the center pixel if the line does not have to originate/end at the centers but rather anywhere on the pixel.
args[0] contains input file name.
args[1] contains output file name.
Prints to stdout number of changes.

Looks great! Can you explain what you mean by 'invalid pixels'? I didn't quite understand that. Also in the image 2 on the bottom right I could not follow why your program 'diggs' into the black wall but then still colour the white dots black again, but i think this has to do with the'invalid pixels' does it?

The few invalid pixels cause a cascade effect that make many more invalid. I will modify the last few images to show the first layer of invalid pixels as green.

Python - PIL - 216,228 108,363 changes total
Whoo! Cut it in half thanks to @AJMansfield! This algorithm skips all the worrying about with calculating lines and optimization and what not. It just changes all whites to black except for one. If there are no whites, it makes one black a white. It check if there are more whites or black and changes every single one of the other kind to it except for one. If there are no black it makes (0, 0) the center.
import Image
from itertools import product

img = Image.open(raw_input())
img = img.convert("RGB")

pixdata = img.load()
changed=0

m=False
count=0
for x, y in product(xrange(img.size[1]), xrange(img.size[0])):
    if pixdata[x, y]==(0, 0, 0):
        count+=1

colors=[(0, 0, 0), (255, 255, 0)] if img.size[0]*img.size[1]-count>count else [(255, 255, 255), (0, 0, 255)]
m=False
for x, y in product(xrange(img.size[1]), xrange(img.size[0])):
    if pixdata[x, y] == colors[0]:
        if m:
            pixdata[x, y] = colors[1]
        else:
            pixdata[x, y] = (255, 0, 0)
            m=True
        changed+=1

if not m:
    pixdata[0, 0]==(255, 0, 0)
    changed+=1
if colors[0]==(255, 255, 255):
    changed-=1

print changed
img.save("out.png", "PNG")

Results
Image 1 - 28688 changes, Image 2 - 24208 changes

Image 3 - 24248 changes, Image 4 - 7103 changes

Image 5 - 11097 changes, Image 6 - 13019 changes

Takes file name from raw_input and writes to out.png and prints number of changes.

Note that the pixels that were changed from black to white should be yellow in your output. Thos that were changed from white to black should be blue, and the center (in your case your only 'white' pixel should be red in your output. Other than that, thank you for participating=) PS: It should always be possible to make a star domain, even when you have a full black image as input, you can change one pixel to white (red).

It can be impossible if there are no white or black pixels (i.e. full color). In any case I'm making the other changes.

Oh. Black & white image. My bad.

I think it might be more efficient to do the opposite strategy, and change all black pixels to white ones. Did you try that?

@AJMansfield I think this would only be more efficient for the given test case, so perhaps this could already be considered as conditioning the algorithm for the given testcases.

I'm doing it so it counts the number of white vs. black pixels and executes the appropriate algorithm.

And. . . done with the optimization! Thanks @AJMansfield

I think you have a typo in the last if statement. Shouldn't that be changed-=1 not changes?

Oh yeah you're right. I just added that line without checking if it worked and subtracted the values manually so I didn't notice. Thanks for the catch.

I think that's the optimal for picture 3.


text:
Translate Prelude to Befunge
This is Weekly Challenge #2. Theme: Translation
Write a program or function that takes in source code for a program in Prelude and outputs code for an equivalent program in Befunge-93. For the program to be equivalent, it should, for any given input, produce the same output as the Prelude program, and halt if and only if the Prelude program halts.
Input language: Prelude
Python interpreter:

#!/usr/bin/python

import sys

NUMERIC_OUTPUT = True
NUMERIC_INPUT = True

try:
    filename = sys.argv[1]
except:
    print "Usage:", sys.argv[0], "<filename>"
    raise SystemExit

try:
    inFile = file(filename)
except:
    print "Error when opening", filename
    raise SystemExit

# code is kept as a list of voices, each voice a string

code = []
firstLine = True
eof = False
while not eof:
    # read batch of lines
    batch = []
    while 1:
        line = inFile.readline()
        if line == '': eof = True
        if line == '' or line.rstrip() == '*':
            break
        batch.append(line.rstrip())
    maxLen = max([len(b) for b in batch])
    batch = [b + ' '*(maxLen - len(b)) for b in batch]
    if firstLine:
        code = batch
        firstLine = False
    else:
        if len(batch) != len(code):
            print "Error in the program: number of voices changes"
            raise SystemExit
        for i in range(len(batch)):
            code[i] += batch[i]

class Stack:
    def __init__(self):
        self.data = []
    def push(self, value):
        if self.data or value != 0: self.data.append(value)
    def drop(self):
        if self.data: self.data.pop()
    def top(self):
        if self.data: return self.data[-1]
        return 0
    def pop(self):
        value = self.top()
        self.drop()
        return value

numVoices = len(code)
numInstructions = len(code[0])
stacks = [Stack() for x in range(numVoices)]
topValues = [0 for x in range(numVoices)]
# establish loop couplings
loopStack = []
loops = {}
for cp in range(numInstructions):
    curr = [voice[cp] for voice in code]
    if curr.count('(') + curr.count(')') > 1:
        print "Error in the program: More than one bracket; position", cp
        raise SystemExit
    if '(' in curr:
        loopStack.append((cp, curr.index('(')))
    if ')' in curr:
        if not loopStack:
            print "Error in the program: extraneous closing bracket; position", cp
            raise SystemExit
        openingPosition, openingVoice = loopStack.pop()
        loops[openingPosition] = cp
        loops[cp] = openingPosition, openingVoice

if loopStack:
    print "Error in the program: not enough closing brackets"
    raise SystemExit

# now, actually execute the program
cp = 0 # code pointer
while cp < numInstructions:
    # technically we're supposed to shuffle our voices to make sure to perform IO
    # in random order, but screw that for now
    next_cp = cp+1 # can be modified by ( )
    for voice in range(numVoices):
        i = code[voice][cp] # current instruction
        if i == '^':
            stacks[voice].push(topValues[(voice-1) % numVoices])
        elif i == 'v' or i == 'V':
            stacks[voice].push(topValues[(voice+1) % numVoices])
        elif i == '+':
            stacks[voice].push(stacks[voice].pop() + stacks[voice].pop())
        elif i == '-':
            b = stacks[voice].pop()
            a = stacks[voice].pop()
            stacks[voice].push(a-b)
        elif i == '#':
            stacks[voice].drop()
        elif i == '?':
            if NUMERIC_INPUT:
                try: num = int(raw_input())
                except ValueError: num = 0
                stacks[voice].push(num)
            else:
                char = sys.stdin.read(1)
                if not char: char = '\0'
                stacks[voice].push(ord(char))
        elif i == '!':
            if NUMERIC_OUTPUT:
                print stacks[voice].pop()
            else:
                sys.stdout.write(chr(stacks[voice].pop()))
        elif i == '(':
            if stacks[voice].top() == 0:
                next_cp = loops[cp] + 1
        elif i == ')':
            openingPosition, openingVoice = loops[cp]
            if topValues[openingVoice] != 0:
                next_cp = openingPosition + 1
        elif i in '0123456789':
            stacks[voice].push(int(i))
    topValues = [stacks[i].top() for i in range(numVoices)]
    cp = next_cp

A Prelude program consists of a number of "voices" which execute instructions simultaneously. The instructions for each voice are on a separate line. Each voice has a separate stack, which is initialized with an infinite amount of zeroes. Execution begins at the leftmost column, and advances one column to the right each tick, except when influenced by ) or ( instructions. The program terminates when the last column is reached.
Prelude spec for this challenge:
Digits 0-9      Push onto the stack a number from 0 to 9. Only single-digit
                    numeric literals can be used.
^               Push onto the stack the top value of the stack of the above
                    voice.
v               Push onto the stack the top value of the stack of the below
                    voice.
#               Remove the top value from the stack.
+               Pop the top two integers from the stack and push their sum.
-               Pop the top two integers from the stack, subtract the topmost
                    from the second, and push the result.
(               If the top of the stack is 0, jump to the column after the
                    matching `)` after the current column executes.
)               If the top of the stack is not 0, jump to the column after
                    the matching `(` after the current column executes.
?               Read an integer from STDIN.
!               Pop one value from the stack and print it to STDOUT as an
                    integer.
<space>         No-op

Notes

v and ^ act cyclically, so the v on the bottom voice will copy the stack element of the top voice, and ^ on the top voice will copy from the bottom voice. Corollary: Both v and ^ duplicate the top of the stack in a single-voice program.
A ( and its matching ) may be located on different lines. However, a ) will always look at the stack of the voice where the corresponding ( was placed, not the stack where the ) itself is placed.
The values produced by the ^ and v instructions operate on the values present prior to the completion of any other operations in the same column.
? and ! operate differently from the specification found on esolangs.org, so be be sure to test with the slightly modified interpreter provided in this post.

Input is guaranteed to have:

Matching parentheses
No more than one parenthesis in a column
Same number of characters on each line
At least one line
No column with more than one I/O (! or ?) instruction
One linefeed character after the instructions for each voice
No characters other than the ones mentioned above

Output language: Befunge-93
Befunge is a stack-based language whose program counter (PC; a pointer to the current instruction) moves freely on a two-dimensional grid. It start in the top left corner, moving to the right. The playfield is toroidal, i.e. PC movement wraps around both edges. Befunge also has a stack which is initialised to an infinite number of zeroes. Befunge has the following operations:

Digits 0-9      Push onto the stack a number from 0 to 9. Only single-digit
                        numeric literals can be used.
    +               Pop the top two integers from the stack and push their sum.
    -               Pop the top two integers from the stack, subtract the topmost
                        from the second, and push the result.
    *               Pop the top two integers from the stack and push their product.
    /               Pop the top two integers from the stack, divide the second by
                        the topmost, and push the result. Rounds down.
    %               Pop the top two integers from the stack, divide the second by
                        the topmost, and push the remainder.
    !               Pop a value, push 1 if it's zero, push 0 otherwise.
    `               Pop the top two integers from the stack, push 1 if the second
                        is greater than the topmost, push 0 otherwise.
    >               Set PC direction to right.
    <               Set PC direction to left.
    ^               Set PC direction to up.
    v               Set PC direction to down.
    ?               Set PC direction randomly.
    _               Pop a value, if it's 0 set PC direction to right, left otherwise.
    |               Pop a value, if it's 0 set PC direction to down, up otherwise.
    "               Toggle string mode. While in string mode, push each character's
                        ASCII value instead of executing it.
    :               Duplicate top stack element.
    \               Swap top two stack elements.
    $               Pop and discard top stack element.
    .               Pop a value and output it as an integer. Whitespace not included.
    ,               Pop a value and output the corresponding ASCII character.
    #               Jump over the next instruction.
    g               Pop y, pop x, push the character at coordinate (x,y).
    p               Pop y, pop x, pop v, set character at coordinate (x,y) to v.
    &               Read an integer from STDIN and push it.
    ~               Read a character from STDIN and push it ASCII value.
    @               End program.

You may assume the following characteristics of the Befunge-93 compiler/interpreter:

Integers are unlimited-precision.
It allows grids of any size.
Grid coordinates (for g and p) are 0-based.

Scoring
In order to prevent submissions which simply produce a Prelude interpreter in Befunge and hardcode the Prelude source into it, the goal will be to minimise the size of the resulting Befunge source code.
Below are provided a number of Prelude programs. Your translator will be run on all of these. Your score is the sum of the sizes of the Befunge programs, provided all of them are valid.
Your translator should not be optimised specifically towards these test cases (e.g. by hardcoding handwritten Befunge programs for them). If I suspect any answer of doing so, I reserve the right to change inputs or create additional ones.
Sample Inputs
Print n-1 down to 0:
?(1-^!)

Logical AND:
?  (0)
 ?(0  )
    1  !

Logical OR:
 ?   (0)
? (0)
   1  1 !

Check parity of input (i.e. modulo 2) of nonnegative number:
?(1-)
 ^  v
 v1-^^-!

Square the input:
 ^
  ^+ !
?(1-)

Print the nth Fibonacci number, where n = 0 corresponds to 0 and n = 1 corresponds to 1:
0 v+v!
1   ^
?(1-)

Signum:
  1) v #  - !
 vv (##^v^+)
?(#   ^   ##

Division for non-negative inputs:
1 (#  1) v #  - 1+)
     vv (##^v^+)
?  v-(0 # ^   #
 ?
   1+              1-!

Of course, your program must exhibit the same behavior for all cases, even if the sample program's behavior for negative numbers is not specified.
Finally, your translator should not be unreasonably long:

It must be contained inside a Stack Exchange post
It should process the sample inputs in under 10 minutes on a typical desktop computer.

Note that a numeric input for Prelude or Befunge is given as an optional minus sign followed by one or more decimal digits, followed by a newline. Other input is undefined behavior.
You may write your translator in any language. Shortest translated Befunge code wins.
Leaderboard

Sp3000: 16430 bytes

I don't understand: "Push onto the stack the top value on the stack of the above voice." Doesn't it has to be: "Push onto the stack the top value of the stack of the above voice."

It says prelude executes voices simultaneously, does that mean they're really executed on a separate thread or can I just executed the first commands on all the voices (top to bottom) then the second commands and so on.

@Deformyer I changed it from "on" to "of", but I thought "top value on the stack" wasn't wrong either. As for simultaneity, no you don't need to actually interpret them in parallel. What's important is that they all act on the previous state of the stacks, and no operation in a given column can affect any other operation in that column.

Don't several of the test cases violate "No column with more than one I/O (! or ?) instruction?"

@proudhaskeller The 1 is inside a loop, so it may not be pushed. A 0 can come from the infinite amount of 0s that start out on the stacks.

@Fuwjax, haskeller Fixed simultaneous I/O.

@proudhaskeller what do you mean by the interpreter rejecting? Matching is done as if all of the parentheses were collapsed into one row.

@feersum i think it fails if the column of the closing paren is smaller than the column of the opening one

@proudhaskeller Yes, looping affects all of the voices, so they always stay together on one column. Can you give a specific example of your interpreter error?

@feersum   (\n) for example

@proudhaskeller That violates the rule No more than one parenthesis in a column

@feersum sorry, the spaces were removed. \s\s(\n). \s is a space.

Could the winning criterion be clarified? I suspect it's intended to be the size of the program when stored as a text file with no trailing spaces on any line. But I can imagine other reasonable meanings of "size" for Befunge programs, like the rectangular area of the program or the number of non-whitespace characters.

@proudhaskeller The opening paren has to be to the left of the closing one.

@Runer112 Your first interpretation is correct.

I've been thinking about how to do this. I started trying to make a Prelude interpreter in Befunge. Keeping track of a variable number of stacks would be really hard.

Python 3, will score later
from collections import defaultdict
from functools import lru_cache
import sys

NUMERIC_OUTPUT = True

@lru_cache(maxsize=1024)
def to_befunge_num(n):
    # Convert number to Befunge number, using base 9 encoding (non-optimal,
    # but something simple is good for now)

    assert isinstance(n, int) and n >= 0

    if n == 0:
        return "0"

    digits = []

    while n:
        digits.append(n%9)
        n //= 9

    output = [str(digits.pop())]

    while digits:
        output.append("9*")
        d = digits.pop()

        if d:
            output.append(str(d))
            output.append("+")

    output = "".join(output)

    if output.startswith("19*"):
        return "9" + output[3:]

    return output

def translate(program_str):
    if program_str.count("(") != program_str.count(")"):
        exit("Error: number of opening and closing parentheses do not match")

    program = program_str.splitlines()
    row_len = max(len(row) for row in program)
    program = [row.ljust(row_len) for row in program]
    num_stacks = len(program)

    loop_offset = 3
    stack_len_offset = program_str.count("(")*2 + loop_offset
    stack_offset = stack_len_offset + 1
    output = [[1, ["v"]], [1, [">"]]] # (len, [strings]) for each row
    max_len = 1 # Maximum row length so far

    HEADER_ROW = 0
    MAIN_ROW = 1
    FOOTER_ROW = 2
    # Then stack lengths, then loop rows, then stacks

    # Match closing parens with opening parens
    loop_map = {} # {column: (loop num, stack number to check, is_start)}
    loop_stack = []
    loop_num = 0

    for col in range(row_len):
        col_str = "".join(program[stack][col] for stack in range(num_stacks))

        if col_str.count("(") + col_str.count(")") >= 2:
            exit("Error: more than one parenthesis in a column")

        if "(" in col_str:
            stack_num = col_str.index("(")

            loop_map[col] = (loop_num, stack_num, True)
            loop_stack.append((loop_num, stack_num, False))
            loop_num += 1

        elif ")" in col_str:
            if loop_stack:
                loop_map[col] = loop_stack.pop()

            else:
                exit("Error: mismatched parentheses")

    def pad_max(row):
        nonlocal max_len, output

        while len(output) - 1 < row:
            output.append([0, []])

        if output[row][0] < max_len:
            output[row][1].append(" "*(max_len - output[row][0]))
            output[row][0] = max_len

    def write(string, row):
        nonlocal max_len, output

        output[row][1].append(string)
        output[row][0] += len(string)

        max_len = max(output[row][0], max_len)

    def stack_len(stack, put=False):
        return (to_befunge_num(stack) + # x
                str(stack_len_offset) + # y
                "gp"[put])

    def get(stack, offset=0):
        assert offset in [0, 1] # 1 needed for 2-arity ops

        # Check stack length
        write(stack_len(stack) + "1-"*(offset == 1) + ":0`", MAIN_ROW)

        pad_max(HEADER_ROW)
        pad_max(MAIN_ROW)
        pad_max(FOOTER_ROW)

        write(">" + to_befunge_num(stack + stack_offset) + "g", HEADER_ROW)
        write("|", MAIN_ROW)
        write(">$0", FOOTER_ROW)

        pad_max(HEADER_ROW)
        pad_max(MAIN_ROW)
        pad_max(FOOTER_ROW)

        write("v", HEADER_ROW)
        write(">", MAIN_ROW)
        write("^", FOOTER_ROW)

    def put(stack, value=""):
        put_inst = (value +
                    stack_len(stack) +
                    to_befunge_num(stack + stack_offset) +
                    "p")

        post_insts.append(put_inst)

    def pop(stack):
        put(stack, "0")

    def inc_stack_len(stack):
        post_insts.append(stack_len(stack) + "1+")
        post_insts.append(stack_len(stack, put=True))

    def dec_stack_len(stack):
        post_insts.append(stack_len(stack) + ":0`-") # Ensure nonnegativity
        post_insts.append(stack_len(stack, put=True))

    # Technically not necessary to initialise stack lengths per spec, but it makes it
    # more portable and easier to test against other Befunge interpreters

    for stack in range(num_stacks):
        write("0" + stack_len(stack, put=True), MAIN_ROW)

    for col in range(row_len):
        post_insts_all = []

        loop_start = False
        loop_end = False

        if col in loop_map:
            if loop_map[col][2]:
                loop_start = True
            else:
                loop_end = True

        if loop_start:
            loop_row = loop_offset + 2*loop_map[col][0]
            get(loop_map[col][1])

        elif loop_end:
            get(loop_map[col][1])
            write("!", MAIN_ROW)

        for stack in range(num_stacks-1, -1, -1):
            char = program[stack][col]
            post_insts = [] # Executed after the gets in reverse order, i.e. last added first

            if char in " ()":
                continue

            # Pre-inc, post-dec
            elif char.isdigit():
                inc_stack_len(stack)
                put(stack, char)

            elif char == "?":
                inc_stack_len(stack)
                put(stack, "&")

            elif char == "!":
                get(stack)
                post_insts.append(".91+," if NUMERIC_OUTPUT else ",")
                pop(stack)
                dec_stack_len(stack)

            elif char == "#":
                pop(stack)
                dec_stack_len(stack)

            elif char in "+-":
                get(stack, 1)
                get(stack)
                post_insts.append(char)
                pop(stack) # This one first in case of ! or 1!
                post_insts.append(stack_len(stack) + ":1`-:1\\`+") # Ensure >= 1
                post_insts.append(stack_len(stack, put=True))
                put(stack)

            elif char in "^v":
                offset = -1 if char == "^" else 1

                get((stack + offset) % num_stacks)
                inc_stack_len(stack)
                put(stack)

            else:
                exit("Error: invalid character " + char)

            post_insts_all.append(post_insts)

        while post_insts_all:
            write("".join(post_insts_all.pop()), MAIN_ROW)

        if loop_start or loop_end:
            loop_row = loop_offset + 2*loop_map[col][0]

            pad_max(HEADER_ROW)
            pad_max(MAIN_ROW)
            pad_max(loop_row)
            pad_max(loop_row + 1)

            write(">v", HEADER_ROW)
            write("|>", MAIN_ROW)

            if loop_start:
                write(" ^", loop_row)
                write(">", loop_row + 1)

            else:
                write("<", loop_row)
                write(" ^", loop_row + 1)

    write("@", MAIN_ROW)
    return "\n".join("".join(row) for row_len, row in output)

if __name__ == '__main__':
    if len(sys.argv) < 3:
        exit("Usage: py -3 prefunge.py <input filename> <output filename>")

    with open(sys.argv[1]) as infile:
        with open(sys.argv[2], "w") as outfile:
            outfile.write(translate(infile.read()))

Run like py -3 prefunge.py <input filename> <output filename>.
It's been a slow week for me, so I was finally bored enough to tackle this six-month old question. I'd ask why nobody else tried, but I'm still feeling the pain from debugging (and there's probably still bugs remaining for all I know).
The question doesn't provide a Befunge-93 interpreter, so I used this one, which is slightly different from the spec. The two key differences are:

If a char doesn't exist in a given row of the program, then you can't write to that row. This means you'll need to hit Enter several times to introduce enough newlines at the end. If you see NaNs in the output, this is the most likely cause.

Grid cells aren't preinitialised to zero - for convenience I've included some preinitialisation in the Befunge outputs, but since it's not necessary I might take it away when I start scoring.

The core layout of the output programs is this:
v [header row]
> [main row]
  [footer row]
  ---
   |
   | rows for loops (2 per loop)
   |
  ---
  [stack length row]
  ---
   |
   | rows for stack space (1 per voice)
   |
  ---

The stack space is outside the program, hence the newline Enter-spamming comment from earlier.
The core idea is to assign each voice a row which serves as its stack. To maintain these stacks, we also have a special stack length row where the length of each stack is recorded in a cell along the row. The program is then a lot of gets and puts, e.g. for printing the process is:

Get the cell at y = stack_row[stack], x = stack_length[stack]
Perform .91+,, i.e. print as integer then print a newline
Replace the cell at the above coords with 0 (to simulate popping)
Decrement stack_length[stack]

To perform the simultaneous evaluation of a column, all necessary cells are read and their values are kept on the stack before any cells are written to (e.g. for the printing example, there may be more instructions in between the first and second steps).
`, which is greater than, is employed to make sure the stack lengths never go negative, and for pushing 0s when the stack is empty. This is where the clearly visible branching comes from, but I've got an idea that'll remove the branching, which should remove a great deal of whitespace from the first and third rows.
For the loops, because Prelude loops can jump both ways, we use two rows per loop in a configuration like this:
       >v                     >v
(cond) |>  (program)  (cond) !|>

        ^                     <
       >                       ^

These loops currently make up the majority of the bytes, but can easily be golfed down by placing them into the codebox with p, which I plan to do after I'm happy that the translator is working correctly.
Here's some example output for ?(1-^!), i.e. print n-1 down to 0:
v                        >6gv>v                      >6gv      >6gv                                 >6gv                   >6gv                           >6gv >v
>005p05g1+05p&05g6p05g:0`|  >|>05g1+05p105g6p05g1-:0`|  >05g:0`|  >-005g6p05g:1`-:1\`+05p05g6p05g:0`|  >05g1+05p05g6p05g:0`|  >.91+,005g6p05g:0`-05p05g:0`|  >!|>@
                         >$0^                        >$0^      >$0^                                 >$0^                   >$0^                           >$0^
                              ^                                                                                <
                             >                                                                                ^

Square-the-input:
v                                >8gv      >8gv             >v      >6gv                                   >8gv      >8gv        >7gv      >7gv                                                            >8gv >v      >7gv
>005p015p025p25g1+25p&25g8p25g:0`|  >25g:0`|  >05g1+05p05g6p|>05g:0`|  >15g1+15p15g7p25g1+25p125g8p25g1-:0`|  >25g:0`|  >15g1-:0`|  >15g:0`|  >+015g7p15g:1`-:1\`+15p15g7p-025g8p25g:1`-:1\`+25p25g8p25g:0`|  >!|>15g:0`|  >.91+,015g7p15g:0`-15p@
                                 >$0^      >$0^                     >$0^                                   >$0^      >$0^        >$0^      >$0^                                                            >$0^         >$0^
                                                             ^                                                                                <
                                                            >                                                                                ^

Division (small inputs are recommended):
v                                                                          >91+gv>v      >94+gv                                                         >95+gv      >95+gv        >93+gv      >93+gv                                                                    >93+gv      >93+gv               >v      >93+gv                                                     >93+gv >v      >92+gv                  >v      >92+gv                                       >92+gv                                       >91+gv                                       >93+gv                     >91+gv                       >92+gv      >92+gv        >91+gv      >91+gv                                                                                >92+gv >v                        >91+gv      >91+gv                                     >91+gv >v                        >95+gv      >95+gv                                     >95+gv
>009p019p029p039p049p09g1+09p109g91+p29g1+29p&29g93+p39g1+39p&39g94+p09g:0`|    >|>39g:0`|    >009g91+p09g:0`-09p29g1+29p29g93+p49g1+49p149g95+p49g1-:0`|    >49g:0`|    >29g1-:0`|    >29g:0`|    >-029g93+p29g:1`-:1\`+29p29g93+p+049g95+p49g:1`-:1\`+49p49g95+p29g:0`|    >29g:0`|    >19g1+19p19g92+p|>29g:0`|    >09g1+09p109g91+p19g1+19p19g92+p29g1+29p029g93+p29g:0`|    >!|>19g:0`|    >029g93+p29g:0`-29p|>19g:0`|    >09g1+09p09g91+p019g92+p19g:0`-19p19g:0`|    >019g92+p19g:0`-19p29g1+29p29g93+p09g:0`|    >009g91+p09g:0`-09p19g1+19p19g92+p29g:0`|    >19g1+19p19g92+p09g:0`|    >19g1+19p19g92+p19g1-:0`|    >19g:0`|    >09g1-:0`|    >09g:0`|    >-009g91+p09g:1`-:1\`+09p09g91+p+019g92+p19g:1`-:1\`+19p19g92+p029g93+p29g:0`-29p19g:0`|    >!|>09g1+09p109g91+p09g1-:0`|    >09g:0`|    >+009g91+p09g:1`-:1\`+09p09g91+p09g:0`|    >!|>49g1+49p149g95+p49g1-:0`|    >49g:0`|    >-049g95+p49g:1`-:1\`+49p49g95+p49g:0`|    >.91+,049g95+p49g:0`-49p@
                                                                           >$0  ^        >$0  ^                                                         >$0  ^      >$0  ^        >$0  ^      >$0  ^                                                                    >$0  ^      >$0  ^                       >$0  ^                                                     >$0  ^         >$0  ^                          >$0  ^                                       >$0  ^                                       >$0  ^                                       >$0  ^                     >$0  ^                       >$0  ^      >$0  ^        >$0  ^      >$0  ^                                                                                >$0  ^                           >$0  ^      >$0  ^                                     >$0  ^                           >$0  ^      >$0  ^                                     >$0  ^
                                                                                ^                                                                                <
                                                                                >                                                                                ^
                                                                                ^                                                                        <
                                                                                >                                                                          ^
                                                                                ^                                                                                <
                                                                                >                                                                                ^

There's also a bunch of other minor optimisations that come to mind, like replacing 07p07g with :07p, but I'm taking this one step at a time :)

So. Much. Free. Time.

Will score later 2 years and counting! :)

5 years and 3 days and counting!

7 years, 5 months and 17 days and counting!


text:
All primes from 0 to 1000
Is it possible to make this C code smaller? It prints out all primes from 0 to 1000.
C, 89 chars
int i,p,c;for(i=2;i<1e3;i++){c=0;for(p=2;p<i;p++)if(i%p==0)c++;if(c==0)printf("%u\n",i);}

Just to pre-empt some "We don't want language-specific challenges" downvotes, asking for help golfing down some code is on-topic and a different story than challenges.

Do we need to preserve the algorithm, or only the end result?

I'd start i at 2 to be strictly accurate, since this prints 0 and 1.

are you trying to make the code execute faster or trying to use less characters in the source code?

Since you're asking for assistance with golf, it would be helpful to include the character count of your current solution in your post (I make it as 89).

There is a better algorithm. Check Sieve of Eratosthenes.

59 57 bytes
Based on @feersum solution but the primality check can be golfed further
for(int p=1,d;d=p++%999;d||printf("%d\n",p))for(;p%d--;);

Edited based on Runer112's comments

The bound check can be golfed a bit more: d=p++%999. Otherwise, this looks pretty airtight golfing job!

67 bytes
In C there's no real alternative to trial division, but it can certainly be golfed a bit.
for(int p=1,d;p++<999;d&&printf("%d\n",p))for(d=p;--d>1;)d=p%d?d:1;

Requires C99 initial declarations, which saves 1 byte.

(I wrote this not realizing the size limitations on integers in C, so it's likely not actually useful for shortening the code.)
First, a word about algorithm. Before golfing your code, you should think about the best overall strategy to get the result.
You're checking primality by doing trial division -- testing each potential divisor p of i. That's costly in characters because it takes two loops. So, testing primality without a loop is likely to save characters.
An often shorter approach is to use Wilson's Theorem: the number n is prime if and only if
fact(n-1)%n == n-1

where fact is the factorial function. Since you're testing all possible n from 1 to 1000, it's easy to avoid implementing factorial by keeping track of the running product P and updating it by P*=n after each loop. Here's a Python implementation of this strategy to print primes up to a million.
Alternatively, the fact that your program only has to be right up to 1000 opens up another strategy: the Fermat primality test. For some a, every prime n satisfies
pow(a,n-1)%n == 1

Unfortunately, some composites n also pass this test for some a. These are called Fermat pseudoprimes. But, a=2 and a=3 don't fail together until n=1105, so they suffice for your purpose of checking primes until 1000. (If 1000 were instead 100, you'd be able to use only a=2.) So, we check primality with (ungolfed code)
pow(2,n-1)%n == 1 and pow(3,n-1)%n == 1

This also fails to recognize primes 2 and 3, so those would need to be special-cased.
Are these approaches shorter? I don't know because I don't code in C. But, they're ideas you should try before you settle on a piece of code to start eking out characters.

Wilson's theorem is not useful in C because ints are 32-bit. Same goes for Fermat's.

@feersum Oh, shoot. That's a problem for the factorials too. Is there a big-int type?

@xnor Not built-in.

if one defines fact(int n, int m) { return (n==0) ? 1 : (n*f(n-1)) % m; } then the result won't overflow a 32 bit integer for even fairly large values of n.  (m is the modulus)

@anorton I think you mean (n*fact(n-1,m)) % m. Which highlights the problem: you cannot avoid the recursion in the implementation of fact because m will be different for each iteration of the outer loop.

@hvd You're right that I meant n*fact(n-1, m)%m, but I don't see how that's a problem.  We want m to be the same for each recursive step (which is what this program does); I'm not sure, but I think that a good compiler should optimize the recursion to an iterative solution, too.

@anorton Yes, but then you've still got a nested loop. Here's a simple version with the recursion manually converted to a loop, so that it's easier to see: there's an outer loop in main, and an inner loop in fact. This answer suggests avoiding the inner loop by remembering fact(n - 1) from the previous iteration and just multiplying that by n, but that's no longer possible when you don't calculate fact(n - 1), when you only calculate fact(n - 1) % m.

78 77 characters
(Just applied some tricks learned in other languages.)
int i=0,p,c;for(;i<1e3;i++){c=0;for(p=2;p<i;)c+=i%p++<1;c||printf("%u\n",i);}

76 characters in C99 mode
for(int i=0,p,c;i<1e3;i++){c=0;for(p=2;p<i;)c+=i%p++<1;c||printf("%u\n",i);}

58 chars (or 61 for a complete program)
Another reuse of my answer to a similar question.
EDIT: stand-alone code piece, no function to call.
for(int m,n=2;n<999;m>1?m=n%m--?m:n++:printf("%d\n",m=n));

Complete program:
n=2;main(m){n<999&&main(m<2?printf("%d\n",n),n:n%m?m-1:n++);}

67 64 bytes
Inspired by Alchymist's solution :
int i=1,p;for(;i++<1e3;p-i||printf("%d\n",i)){p=1;while(i%++p);}


text:
Delivery Robots and Destroyer Drones
Program your robots to deliver packages in a warehouse infested with destroyer
drones. Avoid the drones and get your packages to the right place as fast as you
can.
Delivery Robots

There are packages labeled a-z in a warehouse.
Packages must be delivered to a matching chute A-Z.
A robot cannot move to a square that contains a wall or another robot.
A robot passing over a package will pick it up if it is not holding a package.
A robot landing on a chute will drop their package if the package label matches the chute.

Destroyer Drones

Drones each start with a random heading.
If there is a clear line of sight to robots (NSEW), the drone will move toward the closest visible robot.
If in a dead end or blocked by another drone, the drone will reverse direction.
If at an intersection, a drone will choose a random direction (but not backtrack).
Otherwise, a drone will move on its current heading.
If a robot is ever in one of the four adjacent squares next to a destroyer drone,
that robot is destroyed and disappears. If the robot had a package, it is dropped,
replacing any package or chute already there.
Drones pass over packages.

Warehouse Arena
#################################################
#B             #             #   #      ff      #
############ ##### ######### # # # # ########## #
##### ###          efg*     ## # # #         C# #
#         # ## ############        ############ #
# ###### ## ##         ########## #####         #
#  de  # ## ## ################## ##### ## # ## #
###### # ##    ##      #      ###   ### ## # ## #
#      # ######## ########### ######### ## #  # #
# ######          #    A    #           ## ## # #
# ## ###### #### ## ####### ########### # aeb # #
# ##G       ###  ##    #    ##          ####### #
# ## ###### ### ### ####### ## ########         #
# ######### ### ###      *  ## #        #########
#  cfe   ## ### ####### ###### ########      ## #
######## ## ###     ### ######          ####    #
######## ## ### ### ### ############### ####### #
#               ### ### # # # # # #D# # #$$$$   #
# ###### ##########                     ##### # #
# ###### #### ##### ### ############### ###  ## #
#  #          ##    ###    ##gba        ###     #
# ## ### #### ## ## ### ############### ### #####
# ## ### # *        ### #                       #
# ###### ############## ############### ####### #
#            ########## ##      E  ##         # #
############ ###abc     ## ### ### ## ####### # #
#            ##### ####### ###     ##         # #
# # ######## ##### ####### ### ###### ######### #
# F #                           #     # ccc     #
#################################################

#: wall, $: delivery robot, *: destroyer drone, a-z: package, A-Z: delivery chute
Game Flow
Your program will be called with an arena file argument and MAXTURN integer. The program should follow the logic flow below.
read in arena
for turn in 1..MAXTURN
    for each robot
        optionally move robot to one of four adjacent squares
        if chute here and has matching package
            remove package from robot
            add to score
            if all packages delivered
                add turns bonus
                end game
        if next to drone
            delete robot
            reduce score
        if package here and robot has no package
            add package to robot
            remove package from square
    for each drone
        decide heading using specified rules
        move drone
        if next to any robots
            kill those robots
            drop packages onto map
    if no robots left
        end game

Output
Your program will output your score for that game.
Scoring

The test arena with MAXTURN=5000 will be used for scoring.
You score 500 points for each package delivered.
You lose 900 points for each robot destroyed.
The game ends if all robots are destroyed or MAXTURN turns elapse.
If you deliver all packages, you gain a bonus point for each turn you had remaining.

Your total score will be the sum of the scores of 3 consecutive games.
Your program must not assume this test arena. An arena my be up to 200x200
squares and contain thousands of packages, chutes, robots, and droids. If I
suspect any submission to be tailored towards this specific arena, I reserve the
right to replace it by a new arena. Standard loopholes are prohibited as usual.

Whoa, a challenge of yours that doesn't contain an image. ;) I'm not sure it even matters, but did you check that it's even possible to deliver all 26 packages in 5000 turns with perfect movement ignoring drones? And I think in general it's a bit better for these challenges to provide a controller program, which takes care of stuff like the drones and valid implementation of the game rules, and let people only implement a program that returns the movement directions. That way you wouldn't have to check every single submission that the game is implemented correctly.

I though I would branch out into non-image challenges, just to see if I could do them ;). I calculated an estimate for perfect deliveries and added a contingency factor - should be possible to complete. I did consider a controller, but I ended up with a program flow specification. The PPCG community is pretty good about following the rules. I hope some programmers try it out and have fun.

"The PPCG community is pretty good about following the rules." The PPCG community use to be known for its rule-lawyering, and while it's been moving away from that (fortunately), there are still some people around who like to find and exploit loopholes. (Just as a heads-up.)

The thing that bothers me in this challenge is that I have to write the algorithm for both bots and drones. Pretty sure I will be partial a bit. Also, it takes out the fun of writing the code for just the bots because the drones are pretty much rule bounded and there is no fun in writing them. This would be best served as a KOTH with a common arena for multiple bots trying to get the package at target in the least amount of moves without getting burned.

I like your idea for a KOTH challenge with multiple competing robot teams, and perhaps drones with free programming to make it really hard. I would make an entry for that. My challenge here is a bit different. The drone logic is carefully designed to encourage the robots to cooperate but not overwhelm them. Effective robot teams will distract drones when they get dangerously close to a vulnerable robot (eg: in a dead end passage). I am hoping to see some clever strategies.

That is just the kind of challenge I like, but I agree with Martin about the lack of controller. There are just too many details that would differ from one implementation to another, even trying to follow the specs in good faith.