My experience and the limitations of Brainfuck in this site

Back to General discussions forum

thecornyjoke     2015-10-25 03:43:40
User avatar

I never thought that I wuld have to talk about something so trivial, but here I am anyways.

Before I used the language, I always thought that it was just a silly language that people used as a complete and utter joke. Then, when I used it, I realized that it was more than a toy to play around with, it was a language that forces you to think outside the box instead of going your traditional ways when doing the challenges on this website. I really do enjoy programming in Brainfuck and I've been trying out challenges I've already completed using it.

And then I hit a wall.

With the 1,000,000 operation limit, I can barely do any of the challenges given. Most of the numbers are in the hundreds of thousands and it could take 1/5th of the limit just to add two of them up, given that you can to add and subtract by one, which isn't the language's fault, it's supposed to be minimalistic and simple. This is just a little bit of an annoyance to me and I honestly could just use an application to do the challenges, but I just wanted to tell you about the problem I've had.

Rodion (admin)     2015-10-25 05:14:46
User avatar

Hi, and thank you for sharing your thoughts!

You are mainly right, BF is not good for general tasks here. But have you already tried those problems which are specifically created for it?

Problems filtered by BF tag

I hope they may provide a bit of fun and puzzle. Moreover that more general ones often look very dull in BF :(

The limit of 1mln operations - for which I'm sorry - have two reasons:

  1. Currently interpreter being used is written in PHP and is run on the same site, so it is slow and is subject also to general server restrictions on execution time... 1mln limit mainly ensures that the user gets response before server stops the script. So it is a limitation due to current (rather primitive) infrastructure :)
  2. Some of the BF-specific problems linked above could be solved either in more cunning way, or in some very dull and silly, but very ineffective. So this limit forces people to search for the first kind of solutions :)

Also, as there is a problem on writing BF interpreter, one can create custom implementation in a small time and thus overcome any restricions, though locally. (Strict secret - it is also possible to fetch our BF interpreter from my github and tune it for personal needs). :)

However my personal experience was that after creating (and solving myself) those several problems in BF, it becomes feeling as somewhat dull... So later we created Intel 4004 assembly emulator and problems for it - which is similarly brainf**king but somewhat more powerful. Surely it is also somewhat limited - so I hope we invent something new later...

thecornyjoke     2015-10-25 17:59:07
User avatar

Oh, wow. I didn't know that there are problems dedicated to BF alone! Thanks a bunch!

As for BF getting dull, I guess it would get a little repetitive and tedious to type in a whole bunch of symbols just to multiply to numbers, so I see where you're going with that.

Please login and solve 5 problems to be able to post at forum