3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php echo printf("%.2f", 1).'\n'; echo printf("%.3f", 1).'\n'; echo printf("%.2f", 1.1234).'\n'; ?>
Output for 4.3.7 - 7.1.0
1.004\n1.0005\n1.124\n
Output for 4.3.0 - 4.3.6
1.00\n1.000\n1.12\n