QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#713833#5. 在线 O(1) 逆元Mango201160 5927ms3880kbC++20264b2024-11-05 20:39:382024-11-05 22:08:18

Judging History

你现在查看的是最新测评结果

  • [2024-11-05 22:08:18]
  • 管理员手动重测本题所有提交记录
  • 测评结果:60
  • 用时:5927ms
  • 内存:3880kb
  • [2024-11-05 20:39:38]
  • 评测
  • 测评结果:70
  • 用时:1188ms
  • 内存:3884kb
  • [2024-11-05 20:39:38]
  • 提交

answer

#include<bits/stdc++.h>
#define ll long long
const ll mod=998244353;
int qp(ll x,int y){
	ll res=1;
	while(y){
		if(y&1){
			res=res*x%mod;
		}
		x=x*x%mod;
		y>>=1;
	}
	return res;
}
void init(int p){
	
}
int inv(int x){
 	return qp(x,mod-2);
}

詳細信息


Pretests


Final Tests

Test #1:

score: 10
Accepted
time: 9ms
memory: 3808kb

Test #2:

score: 20
Accepted
time: 1186ms
memory: 3672kb

Test #3:

score: 30
Accepted
time: 5927ms
memory: 3880kb

Test #4:

score: 0
Time Limit Exceeded

Test #5:

score: 0
Time Limit Exceeded