- round: documentation ( source)
<?php
$x = 100;
$y = 100;
$xBonus = $y*0.025;
$yBonus = $x*1.4;
for($i=1;$i<100;$i++){
$xBonus = $yBonus * 0.025;
$yBonus = $xBonus * 1.4;
$x = $x + $xBonus;
$y = $y + $yBonus;
echo 'x-bonus: '. $xBonus . ', y-bonus: '.$yBonus."\n";
echo 'x-gesamt: '. round($x,2) . ', y-gesamt: '.round($y,2)."\n";
}