if you missed the PHP reference implementation here it is: <?php
if (substr(php_sapi_name(), 0, 3) != 'cli') show_source(__FILE__) xor die();
$prog=file_get_contents("php://stdin");
$ascii=false;
$acc=0;
for($i=0;$i<strlen($prog);$i++) {
$c=$prog[$i];
switch($c) {
case 'a': $acc++; break;
case 'b': $acc--; break;
case 'c': if($ascii) echo chr($acc); else echo $acc; break;
case 'd': $acc*=-1; break;
case 'r': $acc=mt_rand(0,$acc); break;
case 'n': $acc=0; break;
case '$': $ascii=!$ascii; break;
case 'l': $i=-1; break;
case ';': echo $acc.chr($acc); break;
}
}