codingtests/solutions/ProjectEuler/013/solve.php
2024-07-01 13:49:44 +00:00

7 lines
153 B
PHP

<?php
$numbers = file('php://stdin');
$total = 0;
foreach($numbers as $number) {
$total = bcadd($total,trim($number));
}
echo substr($total,0,10);