QOJ.ac

QOJ

ID题目提交者结果用时内存语言文件大小提交时间测评时间
#85638#2051. Count The Onesrania__#AC ✓2ms3580kbC++14892b2023-03-07 23:36:412023-03-07 23:36:55

Judging History

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

  • [2023-08-10 23:21:45]
  • System Update: QOJ starts to keep a history of the judgings of all the submissions.
  • [2023-03-07 23:36:55]
  • 评测
  • 测评结果:AC
  • 用时:2ms
  • 内存:3580kb
  • [2023-03-07 23:36:41]
  • 提交

answer

    #include<bits/stdc++.h>
    #include <ext/pb_ds/tree_policy.hpp>
    #include <ext/pb_ds/assoc_container.hpp>

    #define ll long long
    #define endl '\n'
    using namespace std;
    using namespace __gnu_pbds;

    template<typename T>
    using ordered_set = tree<T, null_type, less<T>, rb_tree_tag, tree_order_statistics_node_update>;
    const int N = 1e5+7, P1 = 31, P2 = 37, mod= 1e9 + 7;

    void doWork() {
      int a,b,c;
      cin >> a >> b >> c;
      cout << 1+b-c << endl;
    }


    int main() {
        ios::sync_with_stdio(false);
        cout.tie(nullptr);
        cin.tie(nullptr);
    //    freopen("bisector.in","r",stdin);
    //    freopen("bisector.out","w",stdout);
        int t = 1;
        // cout << primes.size() << endl;
        //cin >> t;
        while (t--) {
            doWork();
        }
        return 0;
    }

詳細信息

Test #1:

score: 100
Accepted
time: 2ms
memory: 3388kb

input:

3 2 1

output:

2

result:

ok answer is '2'

Test #2:

score: 0
Accepted
time: 2ms
memory: 3388kb

input:

10 9 1

output:

9

result:

ok answer is '9'

Test #3:

score: 0
Accepted
time: 2ms
memory: 3408kb

input:

1000000000 999999999 1

output:

999999999

result:

ok answer is '999999999'

Test #4:

score: 0
Accepted
time: 2ms
memory: 3400kb

input:

6 3 2

output:

2

result:

ok answer is '2'

Test #5:

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

input:

100 10 5

output:

6

result:

ok answer is '6'

Test #6:

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

input:

100 99 98

output:

2

result:

ok answer is '2'

Test #7:

score: 0
Accepted
time: 2ms
memory: 3432kb

input:

1000000000 999999999 999999998

output:

2

result:

ok answer is '2'

Test #8:

score: 0
Accepted
time: 2ms
memory: 3396kb

input:

15 10 5

output:

6

result:

ok answer is '6'

Test #9:

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

input:

1000 500 100

output:

401

result:

ok answer is '401'

Test #10:

score: 0
Accepted
time: 1ms
memory: 3552kb

input:

1000000000 999999999 100

output:

999999900

result:

ok answer is '999999900'