x107/B1.php

<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document</title> </head> <body> <?php $dagen = 2; $uren = 3; $minuten = 0; $seconden = 5; function tijd($dagen, $uren, $minuten, $seconden){ $tijd = $dagen*24*3600+$uren*3600+$minuten*60+$seconden; return $tijd; } echo("$dagen dagen, $uren uren, $minuten minuten en $seconden seconden is gelijk aan " . tijd($dagen,$uren,$minuten,$seconden) . " seconden"); ?> </body> </html>

Resultaat

Made by Thijs Aarnoudse