結果

問題 No.73 helloworld
コンテスト
ユーザー roaris
提出日時 2019-12-22 19:44:59
言語 PyPy3
(7.3.17)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
AC  
実行時間 28 ms / 5,000 ms
コード長 388 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 138 ms
コンパイル使用メモリ 85,376 KB
実行使用メモリ 52,224 KB
最終ジャッジ日時 2026-04-04 13:32:46
合計ジャッジ時間 1,163 ms
ジャッジサーバーID
(参考情報)
judge2_0 / judge1_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
other AC * 14
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

C = [int(input()) for _ in range(26)]
alpha = 'abcdefghijklmnopqrstuvwxyz'
idx = {}
c = 0

for alpha_i in alpha:
    idx[alpha_i] = c
    c += 1

h = C[idx['h']]
e = C[idx['e']]
l = C[idx['l']]
o = C[idx['o']]
w = C[idx['w']]
r = C[idx['r']]
d = C[idx['d']]
ans = h*e*(o//2)*(o-o//2)*w*r*d
l_max = 0

for i in range(l+1):
    l_max = max(l_max, i*(i-1)//2*(l-i))

ans *= l_max

print(ans)
0