Question
need the sum to be printed as decimal number
Hi I had written a program to calculate sum of 2 numbers. I need it to be shown as decimal numbers
For example, the input is
0.5+0.5
The output I am getting is
1
The required output is
1.0
I tried parseFloat but it didn't works.