Created
September 7, 2011 00:14
-
-
Save Reinmar/1199370 to your computer and use it in GitHub Desktop.
Brainfuck
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
for(b=[],o='',i=c=l=0;u=s[i++];)l<0?u==']'&&l++:(b.push(0),u=='['?(l=b[c]?i-1:-1):u==']'?i=l:u=='.'?o+=b[c]:u=='+'?++b[c]:u=='-'?--b[c]:u=='>'?++c:u=='<'?--c:o) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
30 bytes is impossible - i tried and i'm nearly sure about that. But I wrote version without loops:
103 chars