Can someone show me how to build a finite state machine that shows modulus 4 in binary?
A:
I'll leave you with this (big) hint: think about how many possible results you can have in modulus-4. Once you know that, you'll know how many states your machine can have.
Matt G.
2009-10-06 20:01:41
+1
A:
Well, a binary number mod 4 is going to be 0 if the last two bits are 00, so that's where you'll want to start. Just think what adding another 1 or 0 to that will do to the last two digits, and do that for each possible state.
Nali4Freedom
2009-10-06 20:05:40