結果
問題 | No.2208 Linear Function |
ユーザー |
|
提出日時 | 2023-02-10 21:22:07 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 54 ms / 2,000 ms |
コード長 | 614 bytes |
コンパイル時間 | 185 ms |
コンパイル使用メモリ | 82,184 KB |
実行使用メモリ | 63,984 KB |
最終ジャッジ日時 | 2024-07-07 15:29:15 |
合計ジャッジ時間 | 833 ms |
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 1 |
other | AC * 3 |
ソースコード
import timeimport sys#sys.setrecursionlimit(500000)def I(): return int(sys.stdin.readline().rstrip())def MI(): return map(int,sys.stdin.readline().rstrip().split())def TI(): return tuple(map(int,sys.stdin.readline().rstrip().split()))def LI(): return list(map(int,sys.stdin.readline().rstrip().split()))def S(): return sys.stdin.readline().rstrip()def LS(): return list(sys.stdin.readline().rstrip())#for i, pi in enumerate(p):from collections import defaultdict,dequeimport bisectimport itertoolsdic = defaultdict(int)d = deque()T = I()for _ in range(T):L,R,A,B = MI()print(max(L*A+B,R*A+B))