I have the below java code snippet:
String str = "0123";
Double dbl = Double.valueOf(str);
The value of dbl become 123.0
But I want to get the value as 0123.0
Is there any way to preserve the leading zero in java?
I have the below java code snippet:
String str = "0123";
Double dbl = Double.valueOf(str);
The value of dbl become 123.0
But I want to get the value as 0123.0
Is there any way to preserve the leading zero in java?