Thanks for posting that code Json.
Type: Posts; User: copeg
Thanks for posting that code Json.
Good point. Out of curiosity though...according to this benchmark below going through the try/catch block is 10 times faster than validation (with correct input of course). For incorrect input the...
If you are unsure of the input, make sure to catch any NumberFormatExceptions that can be thrown when trying to parse something that can't be parsed
public static void main(String[] args) {
...