1. Hi, I need to read the input from the user and use Long.parseLong() to parse it to long datatype.
However, before parsing, I wish to check whether the user has entered the value greater than the max value of long (2^63-1) or smaller than min value of long(-2^63), how to do this?
2. The same question go to BigDecimal. By the way, what is the max and min value for BigDecimal?