結果
| 問題 | No.1989 Pairing Multiset |
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2022-06-24 22:03:39 |
| 言語 | PyPy3 (7.3.23 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 629 ms / 2,000 ms |
| + 633µs | |
| コード長 | 439 bytes |
| 記録 | |
| コンパイル時間 | 63 ms |
| コンパイル使用メモリ | 83,204 KB |
| 実行使用メモリ | 68,552 KB |
| 最終ジャッジ日時 | 2026-09-21 09:12:20 |
| 合計ジャッジ時間 | 9,258 ms |
|
ジャッジサーバーID (参考情報) |
judge2_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 18 |
ソースコード
import sys,random,bisect
from collections import deque,defaultdict
from heapq import heapify,heappop,heappush
from itertools import permutations
from math import log,gcd
input = lambda :sys.stdin.readline().rstrip()
mi = lambda :map(int,input().split())
li = lambda :list(mi())
mod = 998244353
N,M = mi()
res = N
for i in range(2*N+1):
res *= (M+2*N-i) % mod
res %= mod
res *= pow(i+1,mod-2,mod)
res %= mod
print(res)