| Developer's Daily | Java Q&A Center |
| main | java | perl | unix | dev directory | web log |
| Question: | How do I convert a String to a double with Java? |
| Answer: |
|
Converting a String to a double requires that you first convert the String to a Double object, then convert the Double object to a double data type (Double is an object, while double is a primitive data type). An example of a simple program that performs this conversion is shown below:
Other notes
|
Copyright
© 1998-2002 DevDaily Interactive, Inc.
All Rights Reserved.