This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
I have been using the JQ+ tester which has been worth every penny. However I have come across a question which seems wrong. But since they have been always right before, its probably me that's wrong. here is the question: If write(0xAABBCCDD) is called on an instance of FileOutputStream, what will be written to the destination of the stream? They say the answer is - The byte 0xDD But this seems wrong: Here is my reasoning, A Byte can only have a max value of 127 and DD is 221 in hex. In binary this is 11011101. Only the low order bits would be retained for a byte which is 1011101 which is 93, or 5D in hex. What am I missing? Dan