Login  Register

Re: Figuring out zr

Posted by cadet1620 on Jan 25, 2011; 6:47am
URL: http://nand2tetris-questions-and-answers-forum.52.s1.nabble.com/Figuring-out-zr-tp2326310p2327042.html

mbm29414 wrote
What I can't figure out is how the determination is made that "out" is either equal to zero or not based exclusively on messing with out[15]. Obviously, if out[15] = 1, the number can't be zero, since that 1 indicates a non-zero negative number.
'zr' cannot be determined based solely on out[15].  You must determine that out[0..15] are all 0.  Or, conversely, you must determine that out[0..15] are not all 0 to determine 'not zr'.  One of the chips you made in project 1 gets you halfway there...

--Mark