How to Compare 2 Numbers Using 4bit Adder

Thread Starter

athulascc

Joined Aug 15, 2014
94
hi\
I need to compare Number A and B.
I can recognize equal stateCapture.JPG .

Also I know if A>B carry out will be 0.

but how to recognize A<B?
 

Thread Starter

athulascc

Joined Aug 15, 2014
94
please help me assp

I think if A>B then answer is positive therefore Cout=0 , since for A=B Cout=0 when Cout=0 ; A>B or A=B

otherwise A<B

correct?
 

Thread Starter

athulascc

Joined Aug 15, 2014
94
I know substractor does not show answer well when it is out of range or negative.

so I think only looking at carry out is not enough
 

WBahn

Joined Mar 31, 2012
32,827
In your first post you said that you know how to recognize A=B and you know how to recognize A>B (though I'm not convinced you do, but let's assume). Well, then if you determine that A=B is not true AND you determine that A>B is not true, what does that leave as the only possible result?
 
Top