An easy question for everyone

  • Thread starter Simon.Tiplady@gmail.com
  • Start date
S

Simon.Tiplady@gmail.com

Guest
In the following code what does >> represent?

{
do
{
a = In1;
b = In2;
}until (start);

t1 = mod(a);
t2 = mod(b);
x = max(t1,t2);
y = min(t1,t2);
t3 = x >> 3;
t4 = y >> 1;
...
...
}

I`m not bothered about the purpose of the code but what does "t3 = x >>
3" mean?
Is t3 = 1 when x > 3
and t3 = 0 when x < 3?


Thanks,

p.s. quick response please I have an exam on this subject very soon!!!
 
Oops silly me, its just a shift function.

x>>3 shifts the binary complement number 3 to the right
y>>1 shifts 1 position to the right

Simon
 

Welcome to EDABoard.com

Sponsor

Back
Top