posted 22 years ago
I found this info in JLS .
"20.5.23 public static int digit(char ch, int radix)
Returns the numeric value of the character ch considered as a digit in the specified radix. If the value of radix is not a valid radix, or the character ch is not a
valid digit in the specified radix, then -1 is returned. "
ch in your case is 3 which is not a valid digit for radix 2 which has only 2 digits:0,1
[This message has been edited by sai challa (edited April 11, 2001).]