1(xvi)
Which of the following converts "25" to 25.0?
- (a)Double.Parsedouble("25")
- (b)Double.parse("25")
- (c)Double.parseDouble("25")
- (d)Double.parseDouble(25)
Show SolutionHide Solution↓
Double.parseDouble("25")
Reason — In Java, the method Double.parseDouble("25") is used to convert a string containing a numeric value into a double data type. It belongs to the Double class and takes a string as an argument, returning its equivalent double value.