It might have been a better score if I had hit the right keysPaul Anilprem wrote:. . .
Campbell Ritchie wrote:. . . What is wrong with 65%? . . .
Nah, 65% is below passing. No good
That's a pleasureMoussa Kheyar wrote:Thanks
I don't understand that, but it looks incorrect. You have used the leftmost bit as a sign bit, but it has a value.. . . 1111 1111 realy is like below:
(-)111 1111 . . . .
Wikipedia has fallen down there; it calls the leftmost bit the sign bit, which it isn't, even though it always determines the sign of the number, and it incorrectly says that two's complement is determined by inverting the bits and adding 1.Tim Moores wrote:. . . https://en.wikipedia.org/wiki/Two%27s_complement
That is not quite accurate; Java®'s integer primitive types are not defined in sign and magnitude (=S&M) format, but unsigned (chars) or two's complement (all the others). The leftmost bit is regarded as having a value of −128 if you use 8 bits. As Stephan says, complementary arithmetic makes it very easy to implement both addition and subtraction using the same circuits on the chip, which would be much more difficult in S&M. I think that means two's complement is the de facto default format for all signed integer types.Moussa Kheyar wrote:. . . the first bit is used for sign . . .
Why? Java® was not designed as a low‑level language, but platform‑independent, and the interrupts caused by any key being pressed vary from platform to platform.Swapnil Mishra wrote:. . . there has to be a way 😢
If the lock() call is inside the try, and it fails, then the count of unlocks will be greater than the count of locks, and you can rely on something nasty going wrong.Mike Simmons wrote:. . . a finally blocks, from a try started immediately after the lock() was called. . . . .
In which case, maybe you should complain to Amazon.Bertrand Deweer wrote:. . . amazon reading application. . . .
Spain is west of Britain and also on CET.Stephan van Hulst wrote:. . . topographically, we should be in the same time zone as Great Britain.
Our winters were terrible for that very reason, in 1968‑1971. And it was dark before we finished work at 5. That is why summer time doesn't make sense in the Winter. It might in Iceland, where they only have a few hours of daylight in midwinter anyway.. . . our winters would be terrible because it would still be dark at 9 o'clock in the morning. . . . .