Hacker News new | ask | show | jobs
by michaelochurch 4764 days ago
Out of curiosity, am I correct (from your follow-up post) that your cell size is 16-bits (integer range of [0..65535]) and that your tape size is only 256?

I suppose it works but convention seems to be 30,000+ bytes and 8-bit cells. Of course, getting pedantic about brainfuck conventions is a bit beside the point (like Orthodox Discordianism). I just want to know if I'm correct and, if so, I'm curious about what is gained through such nonconventional decisions.

1 comments

I want the core Brainfuck to be as simple and clear-cut as possible. I can implement negative numbers when I get to the assembly stage, and I limited tape size because I'm implementing multiple tapes in the future. I'd rather have many smaller tapes instead of fewer large ones.
That makes a lot of sense. However, I'd still consider your work a success if it broke the 30,000 barrier in cell count. The brainfuck spec says at least 30k cells. It's not an upper limit.

I get why you excluded negative numbers. I was wondering if I was correct in understanding the cell size to be 2 bytes because it's typical for it to be 1 byte.

Am I correct that - on a cell at 0 (or + on a cell at MaxVal) is a no-op, just like < and > at the end of the tape?

You are correct.

Also, we will actually be breaking 30,000 cells. Just not with a single tape :).