Rect.asm is the source for the rect.hack test program used in project 5. The ComputerRect.tst script puts a 4 into memory location 0 before running the program, which keeps it from immediately jumping to the halt loop.
For project 6, it suffices to show that your assembler and the supplied assembler generate the same .hack file for the various .asm files in project 6.
Note the big assumption that was made by the original poster -- that the value of M was zero when the code never stored a value in that location.
In general, when you power up anything that has volatile registers (such as most RAM) you have no idea what values will be stored in each location. As the chips power up each memory cell settles into either a 0 or a 1 depending on a lot of various factors including temperature, variations in transistor threshold, the phase of the moon, you name it. This is why uninitialized memory locations should always be treated as unknown garbage.
So in a program like this, the question that should be asked is whether the program has a logic error because it reads from an uninitialized memory location, or whether there is something else that initializes that memory. This should then prompt you to look at the test script.