結果

問題 No.651 E869120 and Driving
ユーザー mondo
提出日時 2019-08-06 10:03:16
言語 PHP
(843.2)
結果
AC  
実行時間 40 ms / 1,000 ms
コード長 300 bytes
コンパイル時間 256 ms
コンパイル使用メモリ 30,960 KB
実行使用メモリ 31,352 KB
最終ジャッジ日時 2024-07-18 13:51:39
合計ジャッジ時間 984 ms
ジャッジサーバーID
(参考情報)
judge5 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 7
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
$distance = (int)trim(fgets(STDIN));
$speed = 100;
$time = (int)$distance *60 / (int)$speed;
$minutes = $time % 60;
if ($time > 60) {
    if ($time % 60 == 0){
        $minutes = 0;
    } else {
        $minutes = $time % 60;
    }
}
echo (floor($time / 60) + 10).":".sprintf("%02s", $minutes);
0