If I wrote some codes like bellow...
//A program about shift">>"
public class Test1{
public static void main(String[] args){
int num=100;
num=num>>-2;
System.out.println("The result is:"+num);
}
}
Why the result equal to zero??
However I try this : " num=num>>(-2) " ,and I got the same answer...