programming-examples/php/String/PHP script to format values in currency style.php
2019-11-15 12:59:38 +01:00

5 lines
92 B
PHP

<?php
$value1 = 65.45;
$value2 = 104.35;
echo sprintf("%1.2f", $value1+$value2)."\n";
?>