POGAACK

From Esolang
Jump to navigation Jump to search

POGAACK is a Brainfuck-similar programming/joke language specially designed for chicken.

It has 9 commands:

Command Brainfuck eqivalent
pogack! >
pogaack! <
pogaaack! +
poock! -
pogack? [
pogaack? ]
pogaaack? .
poock? ,

Ninth Command is pock!, which repeats the previous command.


Hello World (Chicken language: POGAACK POCK POCK):

pogaaack! pock! pock! pock! pock! pock! pock!
pock! pogack? pogack! pogaaack! pock! pock!
pock! pock! pock! pock! pock! pock! pock!
pogack! pogaaack! pock! pock! pock! pock!
pock! pock! pock! pogack! pogaaack! pock!
pock! pock! pock! pock! pock! pock! pock!
pogack! pogaaack! pock! pock! pock! pogack!
pogaaack! pogaack! pock! pock! pock! pock!
poock! pogaack? pogack! pogaaack? poock!
pogaaack? pogack! pock! poock! pogaaack?
pogaack! pogaaack! pogaaack? pogaaack?
pogaaack! pock! pogaaack? pogack! pogaaack!
pock! pock! pock! pogaaack? pogack! pogaaack?
pogaack! pock! pock! pogaaack! pogaaack?
poock! pogaaack? pogack! pogaaack? pogack!
pogaaack? pogack! pogaaack? pogaack! pock!
pock! pogaaack! pogaaack? poock! pogaaack?
pogack! pogaaack? pogack! pogaaack? pogack!
pock! pogaaack! pock! pogaaack?

Implementation

#!/usr/bin/perl
%c=qw(r ;$p+=1 l ;$p-=1 u ;D+=1 d ;D-=1 b ;D&=255;while(D){ e ;D&=255;} o ;print+chrD i ;D=ord(getc) x +1);
$/=$,;
$_=<>;
$_=uc$_;
s/POGACK!/r/g;
s/POGAACK!/l/g;
s/POGAAACK!/u/g;
s/POOCK!/d/g;
s/POGAAACK\?/o/g;
s/POOCK\?/i/g;
s/POGACK\?/b/g;
s/POGAACK\?/e/g;
s/POCK!/x/g;
s/[^rludiobex]//g;
s/./$c{$&}/g;s[D]'$b[$p]'g;
eval