My code is:
x=new BigDecimal(x.toString()+" "+(new BigDecimal(10).pow(1200)).toString());
I am trying to concat two bigdecimals after converting them to string and then convert them back to bigdecimal.I am doing so because x has a value with a decimal point and multiplying will change its value.It compiles fine but throws a numberformat exception on execution.
My idea was to use the BigDecimal("String x") constructor to convert the string back to BigDecimal.
Note: (for example) x=1333.212 and I am converting it to x=1333.2120000