Anonymous user
Determine if a string is numeric: Difference between revisions
→[[Java]]
Line 43:
==[[Java]]==
[[Category:Java]]
It's generally bad practice in Java to rely on an exception being thrown since exception handling is relatively expensive. If non-numeric strings are common, you're going to see a huge performance hit.
public boolean isNumeric(String input) {
try {
|