Submission #24155463


Source Code Expand

#include<bits/stdc++.h>
#define rep(i,a,b) for(int i=a;i<b;i++)
#define rrep(i,a,b) for(int i=a;i>=b;i--)
#define fore(i,a) for(auto &i:a)
#define all(x) (x).begin(),(x).end()
//#pragma GCC optimize ("-O3")
using namespace std;
void _main(); int main() { cin.tie(0); ios::sync_with_stdio(false); _main(); }
typedef long long ll; const int inf = INT_MAX / 2; const ll infl = 1LL << 60;
template<class T>bool chmax(T& a, const T& b) { if (a < b) { a = b; return 1; } return 0; }
template<class T>bool chmin(T& a, const T& b) { if (b < a) { a = b; return 1; } return 0; }
//---------------------------------------------------------------------------------------------------
/*---------------------------------------------------------------------------------------------------
            ∧_∧
      ∧_∧  (´<_` )  Welcome to My Coding Space!
     ( ´_ゝ`) /  ⌒i     @hamayanhamayan0
    /   \     | |
    /   / ̄ ̄ ̄ ̄/  |
  __(__ニつ/     _/ .| .|____
     \/____/ (u ⊃
---------------------------------------------------------------------------------------------------*/














int A, B;
//---------------------------------------------------------------------------------------------------
void _main() {
	cin >> A >> B;
	int ans = 0;
	rep(x, A, B + 1) ans++;
	cout << ans << endl;
}





Submission Info

Submission Time
Task A - Counting
User hamayanhamayan
Language C++ (GCC 9.2.1)
Score 100
Code Size 1502 Byte
Status AC
Exec Time 10 ms
Memory 3612 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 100 / 100
Status
AC × 3
AC × 9
Set Name Test Cases
Sample sample_00.txt, sample_01.txt, sample_02.txt
All case_00.txt, case_01.txt, case_02.txt, case_03.txt, case_04.txt, case_05.txt, sample_00.txt, sample_01.txt, sample_02.txt
Case Name Status Exec Time Memory
case_00.txt AC 10 ms 3532 KiB
case_01.txt AC 2 ms 3472 KiB
case_02.txt AC 2 ms 3500 KiB
case_03.txt AC 2 ms 3420 KiB
case_04.txt AC 3 ms 3532 KiB
case_05.txt AC 2 ms 3476 KiB
sample_00.txt AC 2 ms 3420 KiB
sample_01.txt AC 2 ms 3500 KiB
sample_02.txt AC 2 ms 3612 KiB