Im a PHP-programmer and wonder what this line means.
System.out.printf("exp(%.3f) is %.3f%n", x, Math.exp(x))
what does %.3f, %.3f%n and the comma x means?
It is similar to C's printf:
http://java.sun.com/j2se/1.5.0/docs/api/java/util/Formatter.html#syntax
PHP has a similar function: http://php.net/printf The Documentation of the Java version can be found here: http://java.sun.com/javase/6/docs/api/java/util/Formatter.html
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With