- Edited
There are two solutions for removing the limit from 255. You can either have a something like:Joe wroteI still struggle to manipulate numbers higher than 255. However assuming very low numbers (like 1 and 2), this is actually a good exercise. I think Johnaudi meant single digit.
@NuclearVision: I don't think your code works. Maybe you miscopied part of it? Why would you start going to the left when you're in cell0?
[0],[1],[2]
0,3,42
[0] is pointer 0, and has the value of 0.
In [1] you have the value 3, which is in definition, 3 times 255, and in [2] you have 42, so in total the number is: 3*255 + 42 = 802.
Once [1] reaches the limit (255++ == 0) then [0] will have a value added to it.
The other (easier) solution, most compilers (such as http://copy.sh/brainfuck ) have an option to where you can adjust the cell size from 8 Bits (255) to 32 bits.