結果
| 問題 | No.2043 Ohuton and Makura |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-08-19 22:07:48 |
| 言語 | PyPy3 (7.3.17) |
| 結果 |
AC
|
| 実行時間 | 56 ms / 2,000 ms |
| コード長 | 490 bytes |
| 記録 | |
| コンパイル時間 | 176 ms |
| コンパイル使用メモリ | 85,120 KB |
| 実行使用メモリ | 64,128 KB |
| 最終ジャッジ日時 | 2026-04-24 15:01:04 |
| 合計ジャッジ時間 | 2,336 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge3_1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 18 |
ソースコード
import sys,random,bisect
from collections import deque,defaultdict,Counter
from heapq import heapify,heappop,heappush
from itertools import cycle, permutations
from math import log,gcd
input = lambda :sys.stdin.readline().rstrip()
mi = lambda :map(int,input().split())
li = lambda :list(mi())
A,B,S = mi()
res = 0
for h in range(1,S+1):
w_max = min(S//h,B)
if h <= A:
#res += (A-h+1) * (B-w+1)
res += (A-h+1) * (w_max * (B+1) - w_max * (w_max+1)//2)
print(res)