Hi
Regarding 3)
The operands are being accepted as Octal and with the help of conversion system we know
00001010 in Octal = 512 in decimal System
00001000 in Octal = 520 in decimal System
Now the 3) statment becomes
System.out.println(512^520);
giving you 8.
(I hope that u wont ask for: how 512^520=8???)