Convert Float to String in Java
Description
The following code shows how to convert Float to String.
Example
/*ww w. j a v a 2s . com*/
public class Main {
public static void main(String[] args) {
Float fObj = new Float(10.25);
String str = fObj.toString();
System.out.println(str);
}
}
The code above generates the following result.
Home »
Java Tutorial »
Java Data Type »
Java Tutorial »
Java Data Type »