結果

問題 No.525 二度寝の季節
ユーザー ayaaya
提出日時 2019-07-31 17:59:54
言語 PHP
(8.3.4)
結果
AC  
実行時間 20 ms / 1,000 ms
コード長 426 bytes
コンパイル時間 539 ms
コンパイル使用メモリ 18,584 KB
実行使用メモリ 19,016 KB
最終ジャッジ日時 2023-09-18 16:33:48
合計ジャッジ時間 2,069 ms
ジャッジサーバーID
(参考情報)
judge12 / judge13
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 19 ms
18,880 KB
testcase_01 AC 20 ms
19,016 KB
testcase_02 AC 20 ms
18,904 KB
testcase_03 AC 20 ms
19,012 KB
testcase_04 AC 20 ms
18,976 KB
testcase_05 AC 19 ms
18,876 KB
testcase_06 AC 19 ms
18,964 KB
testcase_07 AC 20 ms
18,912 KB
testcase_08 AC 20 ms
18,756 KB
testcase_09 AC 20 ms
18,884 KB
testcase_10 AC 20 ms
18,908 KB
testcase_11 AC 20 ms
18,908 KB
testcase_12 AC 19 ms
18,940 KB
testcase_13 AC 19 ms
18,904 KB
testcase_14 AC 20 ms
18,848 KB
testcase_15 AC 19 ms
18,904 KB
testcase_16 AC 19 ms
18,932 KB
testcase_17 AC 20 ms
18,896 KB
testcase_18 AC 19 ms
18,760 KB
testcase_19 AC 20 ms
19,004 KB
testcase_20 AC 19 ms
18,900 KB
testcase_21 AC 20 ms
18,876 KB
testcase_22 AC 20 ms
18,984 KB
testcase_23 AC 19 ms
18,968 KB
testcase_24 AC 20 ms
18,756 KB
testcase_25 AC 19 ms
18,944 KB
testcase_26 AC 19 ms
18,908 KB
testcase_27 AC 20 ms
18,904 KB
testcase_28 AC 20 ms
18,756 KB
testcase_29 AC 20 ms
18,872 KB
testcase_30 AC 20 ms
18,984 KB
testcase_31 AC 20 ms
18,884 KB
testcase_32 AC 19 ms
18,880 KB
testcase_33 AC 20 ms
18,836 KB
testcase_34 AC 19 ms
19,016 KB
権限があれば一括ダウンロードができます
コンパイルメッセージ
No syntax errors detected in Main.php

ソースコード

diff #

<?php
$date = date_create("now");
$input=explode(":",(fgets(STDIN)));
$min=(int)$input[1]+5;
$hour=(int)$input[0];
if($min>=60){
  $min=sprintf('%02d',$min-60);
  $hour=1+(int)$input[0];
  if($hour>=24){
    $hour=sprintf('%02d',$hour-24);
  }else{
    $hour=sprintf('%02d',$hour);
  }
}else{
  $min=sprintf('%02d',$min);
  $hour=sprintf('%02d',$hour);
}
date_time_set($date,$hour,$min);
echo date_format($date, 'H:i') . "\n";
0