Is there any way we can tell the compiler that is not an octal or something like that. I know in place of 08 I can take as 8, but that will not work in my case.
Why are you using octal notation if you don't want octal numbers? You've already gone to the extra effort of telling the compiler that it is an octal number. [ July 31, 2008: Message edited by: Paul Sturrock ]
An octal numeral consists of an ASCII digit 0 followed by one or more of the ASCII digits 0 through 7 and can represent a positive, zero, or negative integer.
Note that octal numerals always consist of two or more digits; 0 is always considered to be a decimal numeral-not that it matters much in practice, for the numerals 0, 00, and 0x0 all represent exactly the same integer value. - Java Spec
Bill Shirley - bshirley - frazerbilt.com
if (Posts < 30) you.read( JavaRanchFAQ);
Originally posted by RACHIT JAIN: I know in place of 08 I can take as 8, but that will not work in my case.
Can you tell us WHY that won't work in your case? the number '08' is exactly the same as the number '8' (mathematically speaking - in java, the two literals have a different meaning). We can't see why it would make any difference which you use when building your hashmap, so you have to give us an explanation if we are to give you any more advice.
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Joined: Mar 05, 2008
This thread is from last July, so I doubt we'll get any new clarification from the original poster.