結果

問題 No.785 色食い虫
ユーザー maspy
提出日時 2020-01-18 17:45:22
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 31 ms / 2,000 ms
コード長 271 bytes
コンパイル時間 75 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 10,496 KB
最終ジャッジ日時 2024-06-27 22:09:07
合計ジャッジ時間 2,099 ms
ジャッジサーバーID
(参考情報)
judge2 / judge5
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 28
権限があれば一括ダウンロードができます

ソースコード

diff #

import sys
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

R,G,B = readlines()

def f(R):
    if R == b'NONE\n':
        return 16
    return 15 - R.count(b',')

x = f(R) * f(G) * f(B)
answer = x * x
print(answer)
0