And I'm back with more of this excitement. As the title says, I'm on to arrays. I have two number sorting problems to get done, and I figure arrays are going to be the best way to go about it. For those of you who don't know, I am using a program called MARIE, which is basically this program that simulates a super small instruction set.
Ok, on to the problem. I realize I'm going to need to kind of "fake" a pointer to a block of memory. I can do this no problem in C, but I can't figure it out with marie.
1 2 3 4 5
Arr, Dec 0
Dec 0
Dec 0
Dec 0
Dec 0
This is what I have for an array. Memory locations are implied, but they're all contiguous. So if I get this pointer to Arr figured out, all I have to do is add X to that pointer and I can access any element of the array. I'm not sure how to simulate a pointer with this instruction set though. :(