QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#439261#8788. Page on vdome.comsupepapupuAC ✓0ms3668kbC++201.3kb2024-06-11 18:40:432024-06-11 18:40:44

Judging History

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

  • [2024-06-11 18:40:44]
  • 评测
  • 测评结果:AC
  • 用时:0ms
  • 内存:3668kb
  • [2024-06-11 18:40:43]
  • 提交

answer

#include <bits/stdc++.h>

#define x first
#define y second
#define el '\n'
#define debug(x) cerr << #x << ": " << x << el
using namespace std;
typedef long long ll;
typedef pair<int, int> pii;
typedef pair<ll, ll> pll;
const int N = 3e5 + 10, INF = 0x3f3f3f3f, mod = 998244353;

void inc(ll &a, ll b) {
    a += b;
    if (a >= mod) a -= mod;
}
void dec(ll &a, ll b) {
    a -= b;
    if (a < 0) a += mod;
}
ll add(ll a, ll b) {
    a += b;
    return a >= mod ? a - mod : a;
}
ll del(ll a, ll b) {
    a -= b;
    return a < 0 ? a + mod : a;
}
ll qmi(ll a, ll b) {
    ll res = 1;
    while (b) {
        if (b & 1) res = res * a % mod;
        a = a * a % mod;
        b >>= 1;
    }
    return res;
}
ll inv(ll a) {
    return qmi(a, mod - 2);
}

struct Comb {
    vector<ll> fac, ifac;
    Comb(int n) : fac(n + 1), ifac(n + 1) {
        fac[0] = 1;
        for (int i = 1; i <= n; ++i) fac[i] = fac[i - 1] * i % mod;
        ifac[n] = inv(fac[n]);
        for (int i = n; i; --i) ifac[i - 1] = ifac[i] * i % mod;
    }
    ll binom(int a, int b) {
        return fac[a] * ifac[b] % mod * ifac[a - b] % mod;
    }
};

int main() {
    ios::sync_with_stdio(0); cin.tie(0);
    int n; cin >> n;
    if (n <= 9) cout << n + 1 << el;
    else cout << 10 << el;
}

这程序好像有点Bug,我给组数据试试?

详细

Test #1:

score: 100
Accepted
time: 0ms
memory: 3628kb

input:

5

output:

6

result:

ok 1 number(s): "6"

Test #2:

score: 0
Accepted
time: 0ms
memory: 3640kb

input:

10

output:

10

result:

ok 1 number(s): "10"

Test #3:

score: 0
Accepted
time: 0ms
memory: 3564kb

input:

9

output:

10

result:

ok 1 number(s): "10"

Test #4:

score: 0
Accepted
time: 0ms
memory: 3612kb

input:

1

output:

2

result:

ok 1 number(s): "2"

Test #5:

score: 0
Accepted
time: 0ms
memory: 3616kb

input:

2

output:

3

result:

ok 1 number(s): "3"

Test #6:

score: 0
Accepted
time: 0ms
memory: 3512kb

input:

4

output:

5

result:

ok 1 number(s): "5"

Test #7:

score: 0
Accepted
time: 0ms
memory: 3572kb

input:

11

output:

10

result:

ok 1 number(s): "10"

Test #8:

score: 0
Accepted
time: 0ms
memory: 3644kb

input:

19

output:

10

result:

ok 1 number(s): "10"

Test #9:

score: 0
Accepted
time: 0ms
memory: 3628kb

input:

20

output:

10

result:

ok 1 number(s): "10"

Test #10:

score: 0
Accepted
time: 0ms
memory: 3580kb

input:

99

output:

10

result:

ok 1 number(s): "10"

Test #11:

score: 0
Accepted
time: 0ms
memory: 3612kb

input:

100

output:

10

result:

ok 1 number(s): "10"

Test #12:

score: 0
Accepted
time: 0ms
memory: 3624kb

input:

101

output:

10

result:

ok 1 number(s): "10"

Test #13:

score: 0
Accepted
time: 0ms
memory: 3668kb

input:

110

output:

10

result:

ok 1 number(s): "10"

Test #14:

score: 0
Accepted
time: 0ms
memory: 3556kb

input:

12345

output:

10

result:

ok 1 number(s): "10"

Test #15:

score: 0
Accepted
time: 0ms
memory: 3544kb

input:

123456789

output:

10

result:

ok 1 number(s): "10"

Test #16:

score: 0
Accepted
time: 0ms
memory: 3628kb

input:

584392706

output:

10

result:

ok 1 number(s): "10"

Test #17:

score: 0
Accepted
time: 0ms
memory: 3544kb

input:

987654321

output:

10

result:

ok 1 number(s): "10"

Test #18:

score: 0
Accepted
time: 0ms
memory: 3620kb

input:

1000000000

output:

10

result:

ok 1 number(s): "10"

Extra Test:

score: 0
Extra Test Passed