結果

問題 No.73 helloworld
ユーザー jjjj
提出日時 2016-09-13 22:50:29
言語 Fortran
(gFortran 13.2.0)
結果
WA  
実行時間 -
コード長 592 bytes
コンパイル時間 130 ms
コンパイル使用メモリ 32,256 KB
実行使用メモリ 6,944 KB
最終ジャッジ日時 2024-04-28 13:16:09
合計ジャッジ時間 703 ms
ジャッジサーバーID
(参考情報)
judge1 / judge2
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 WA -
testcase_01 AC 1 ms
6,940 KB
testcase_02 AC 1 ms
6,940 KB
testcase_03 AC 1 ms
6,944 KB
testcase_04 AC 1 ms
6,940 KB
testcase_05 WA -
testcase_06 AC 2 ms
6,940 KB
testcase_07 WA -
testcase_08 AC 1 ms
6,940 KB
testcase_09 WA -
testcase_10 WA -
testcase_11 WA -
testcase_12 AC 1 ms
6,940 KB
testcase_13 AC 1 ms
6,944 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

program main
  implicit none
  integer*8::C(26)
  integer*8::h,e,l,o,w,r,d
  integer*8::m
  real::x,n
  read *,C
  h = C(8)
  e = C(5)
  l = C(12)
  o = C(15)
  w = C(23)
  r = C(18)
  d = C(4)
  if(h.lt.1 .or. &
     e.lt.1 .or. &
     l.lt.3 .or. &
     o.lt.2 .or. &
     w.lt.1 .or. &
     r.lt.1 .or. &
     d.lt.1) then
     print '(i0)',0

  else
     m = get_max(l)
     print '(i0)',h*e*m*(o-1)*w*r*d
  end if
contains
  function get_max(l) result(m)
    integer*8::i,m,l
    m = 1
    do i=2,l-1
       m = MAX(m, (l-i)*i*(i-1)/2)
    end do
  end function get_max
end program main
0