alexjercan/bugnet huggingface dataset:
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {

  // 文字列
  string str;
  cin >> str;

  if (str.at(2) == str.at(3) && str.at(4) == str.at(5)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {

  // 文字列
  string str;
  cin >> str;

  if (str.at(3) == str.at(4) && str.at(5) == str.at(6)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {
  string ch;
  cin >> ch;
  if (ch.at(2) == ch.at(3) && ch.at(4) == ch.at(5)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {
  string ch;
  cin >> ch;
  bool ans = false;
  if (ch.at(3) == ch.at(4) && ch.at(5) == ch.at(6)) {
    ans == true;
  }
  if (ans) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {
  string A;
  cin >> A;
  if (A[3] == A[2] && A[5] == A[4])
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {
  string A;
  cin >> A;
  if (A.at(3) == A.at(4) && A.at(5) == A.at(6))
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  string a;
  cin >> a;
  if (a.at(2) == a.at(3) && a.at(4) == a.at(5)) {
    cout << "Yes" << endl;
    return 0;
  }
  cout << "No" << endl;
}


Error: -6
terminate called after throwing an instance of 'std::out_of_range'
  what():  basic_string::at: __n (which is 2) >= this->size() (which is 0)


Fixed submission:

#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  string a;
  if (a.at(2) == a.at(3) && a.at(4) == a.at(5)) {
    cout << "Yes" << endl;
    return 0;
  }
  cout << "No" << endl;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
#define ll long long int
#define FASTIO std::ios::sync_with_stdio(false);
#define pb push_back
#define mp make_pair
#define F first
#define S second
#define inf 1e18
#define g(x) cout << x << " " << endl;
#define gg(x, y) cout << x << " & " << y << " " << endl
#define jam(t) cout << "Case #" << t << ": "
#define ggg(x, y, z) cout << x << " & " << y << " & " << z << " " << endl
#define all(x) x.begin(), x.end()
#define input_from_file freopen("input.txt", "r", stdin);
#define mod 1000000007ll
#define sz 400005
#define bitcnt(x) __builtin_popcountll(x)
#define trace(...) __f(#__VA_ARGS__, __VA_ARGS__)
using namespace std;
template <typename Arg1> void __f(const char *name, Arg1 &&arg1) {
  cout << name << " : " << arg1 << endl;
}
template <typename Arg1, typename... Args>
void __f(const char *names, Arg1 &&arg1, Args &&...args) {
  const char *comma = strchr(names + 1, ',');
  cout.write(names, comma - names) << " : " << arg1 << " | ";
  __f(comma + 1, args...);
}

void solve() {
  string s;
  cin >> s;
  if (s[3] == s[2] && s[4] == s[5]) {
    g("Yes");
    return;
  }
  g("No");
}
int main() {

  FASTIO
  cin.tie(NULL);
  fflush(stdout);
  ll t = 1;
  // cin >> t;
  for (ll tcase = 1; tcase <= t; tcase++) {
    solve();
  }
  return 0;
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
#define ll long long int
#define FASTIO std::ios::sync_with_stdio(false);
#define pb push_back
#define mp make_pair
#define F first
#define S second
#define inf 1e18
#define g(x) cout << x << " " << endl;
#define gg(x, y) cout << x << " & " << y << " " << endl
#define jam(t) cout << "Case #" << t << ": "
#define ggg(x, y, z) cout << x << " & " << y << " & " << z << " " << endl
#define all(x) x.begin(), x.end()
#define input_from_file freopen("input.txt", "r", stdin);
#define mod 1000000007ll
#define sz 400005
#define bitcnt(x) __builtin_popcountll(x)
#define trace(...) __f(#__VA_ARGS__, __VA_ARGS__)
using namespace std;
template <typename Arg1> void __f(const char *name, Arg1 &&arg1) {
  cout << name << " : " << arg1 << endl;
}
template <typename Arg1, typename... Args>
void __f(const char *names, Arg1 &&arg1, Args &&...args) {
  const char *comma = strchr(names + 1, ',');
  cout.write(names, comma - names) << " : " << arg1 << " | ";
  __f(comma + 1, args...);
}

void solve() {
  string s;
  cin >> s;
  if (s[3] == s[2] && s[4] == s[5]) {
    g("Yes");
    return;
  }
  g("No");
}
int main() {
#ifndef ONLINE_JUDGE
  input_from_file
#endif

      FASTIO cin.tie(NULL);
  fflush(stdout);
  ll t = 1;
  // cin >> t;
  for (ll tcase = 1; tcase <= t; tcase++) {
    solve();
  }
  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;
const int M = 100005;
long long int N = 1e9 + 7;
long long int Z = 998244353;
/*int fac[M]={0};*/
// int dp[M]={0};
#define ll long long
int gcd(int a, int b) {
  if (b == 0)
    return a;
  return gcd(b, a % b);
}
// Use __gcd(int, int) as inbuilt function.
void precompute() {}
int max3(int x, int y, int z) { return max(x, max(y, z)); }
long long int power(long long int x, unsigned int y, int p) {
  long long int res = 1; // Initialize result

  x = x % p; // Update x if it is more than or
             // equal to p

  while (y > 0) {
    // If y is odd, multiply x with result
    if (y & 1)
      res = (res * x) % p;

    // y must be even now
    y = y >> 1; // y = y/2
    x = (x * x) % p;
  }
  return res;
}
long long int modinv(long long int x, int p) { return (power(x, p - 2, p)); }
bool compare(const pair<int, int> &p1, const pair<int, int> &p2) {
  return (p1.first > p2.first);
}
/*long long int nCrModP(long long int n, long long int r, long long int p)
{
   if (r==0)
      return 1;
    return (fac[n] * modinv(fac[r], p) % p * modinv(fac[n-r], p) % p) % p;
}*/

int main() {

  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  string s;
  cin >> s;
  if ((s[2] == s[3]) && (s[4] == s[5])) {
    cout << "Yes";
  } else {
    cout << "No";
  }
  return 0;
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;
const int M = 100005;
long long int N = 1e9 + 7;
long long int Z = 998244353;
/*int fac[M]={0};*/
// int dp[M]={0};
#define ll long long
int gcd(int a, int b) {
  if (b == 0)
    return a;
  return gcd(b, a % b);
}
// Use __gcd(int, int) as inbuilt function.
void precompute() {}
int max3(int x, int y, int z) { return max(x, max(y, z)); }
long long int power(long long int x, unsigned int y, int p) {
  long long int res = 1; // Initialize result

  x = x % p; // Update x if it is more than or
             // equal to p

  while (y > 0) {
    // If y is odd, multiply x with result
    if (y & 1)
      res = (res * x) % p;

    // y must be even now
    y = y >> 1; // y = y/2
    x = (x * x) % p;
  }
  return res;
}
long long int modinv(long long int x, int p) { return (power(x, p - 2, p)); }
bool compare(const pair<int, int> &p1, const pair<int, int> &p2) {
  return (p1.first > p2.first);
}
/*long long int nCrModP(long long int n, long long int r, long long int p)
{
   if (r==0)
      return 1;
    return (fac[n] * modinv(fac[r], p) % p * modinv(fac[n-r], p) % p) % p;
}*/

int main() {
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif // ONLINE_JUDGE
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  precompute();
  string s;
  cin >> s;
  if ((s[2] == s[3]) && (s[4] == s[5])) {
    cout << "Yes";
  } else {
    cout << "No";
  }
  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;
#define lli long long int
void c_p_c() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif
}
int main() {
  // c_p_c();
  string c;
  cin >> c;
  if (c[2] == c[3] && c[4] == c[5]) {
    cout << "Yes";
  } else
    cout << "No";
  return 0;
  //    lli c;  cin>>c;
  //    lli hap=0;
  //    hap+=c/500;
  //    hap*=1000;
  //    c-=500*(c/500);
  //    hap+=5*(c/5);
  //    cout<<hap;
  //    return 0;
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;
#define lli long long int
void c_p_c() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif
}
int main() {
  c_p_c();
  string c;
  cin >> c;
  if (c.length() > 4 && (c[2] == c[3] && c[4] == c[5])) {
    cout << "YES";
  } else
    cout << "NO";
  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>

using namespace std;

int main() {
  // #ifndef ONLINE_JUDGE
  //     freopen("input.txt", "r", stdin);
  //     freopen("output.txt", "w", stdout);
  // #endif

  string s;
  cin >> s;
  assert((int)s.size() == 6);
  if (s[2] == s[3] and s[4] == s[5]) {
    cout << "Yes";
  } else
    cout << "No";
}

Error: -6
eddea575-dcb0-4d16-8522-fed2fe00b013.out: /home/alex/Documents/bug-detection/input/Project_CodeNet/data/p02723/C++/s087558683.cpp:14: int main(): Assertion `(int)s.size()==6' failed.


Fixed submission:

#include <bits/stdc++.h>

using namespace std;

int main() {
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif

  string s;
  cin >> s;
  assert((int)s.size() == 6);
  if (s[2] == s[3] and s[4] == s[5]) {
    cout << "Yes";
  } else
    cout << "No";
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <stdio.h>
#include <string.h>
int main() {
  char S[10];
  scanf("%s", S);
  ((S[2] == S[3]) && (S[4] == S[5])) ? (printf("Yes\\n")) : (printf("No\\n"));
}

Error: -6
*** stack smashing detected ***: terminated


Fixed submission:

#include <stdio.h>

int main() {
  char S[5];
  scanf("%s", &S);
  if (S[2] == S[3] && S[4] == S[5]) {
    printf("Yes\\n");
  } else {
    printf("No\\n");
  }
  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  if (s.at(2) == s.at(3) && s.at(4) == s.at(5))
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  if (s.at(3) == s.at(4) && s.at(5) == s.at(6))
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {

  char s[6];
  cin >> s;
  if (s[2] == s[3] && s[4] == s[5]) {
    cout << "Yes\\n";
  } else {
    cout << "No\\n";
  }

  return 0;
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif
  ios::sync_with_stdio(0);
  cin.tie(0);
  // Write from here.

  char s[6];
  cin >> s;
  if (s[2] == s[3] && s[4] == s[5]) {
    cout << "Yes\\n";
  } else {
    cout << "No\\n";
  }

  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
#include <math.h>

#define IOS                                                                    \\
  ios::sync_with_stdio(0);                                                     \\
  cin.tie(0);                                                                  \\
  cout.tie(0);
#define endl "\\n"
#define ll long long
#define pii pair<int, int>
#define all(x) begin(x), end(x)
#define loop(i, n) for (int i = 0; i < n; i++)
#define rep(i, a, b, c) for (int i = a; i < b; i += c)
#define brep(i, a, b, c) for (int i = a; i > b; i -= c)
#define tc(t)                                                                  \\
  int t;                                                                       \\
  cin >> t;                                                                    \\
  while (t--)
#define sz(v) int((v).size())
#define pb push_back

using namespace std;

int main() {

  IOS;

  string s;
  cin >> s;

  if (s[2] == s[3] && s[4] == s[5]) {
    cout << "Yes";
  } else {
    cout << "No";
  }

  return 0;
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
#include <math.h>

#define IOS                                                                    \\
  ios::sync_with_stdio(0);                                                     \\
  cin.tie(0);                                                                  \\
  cout.tie(0);
#define endl "\\n"
#define ll long long
#define pii pair<int, int>
#define all(x) begin(x), end(x)
#define loop(i, n) for (int i = 0; i < n; i++)
#define rep(i, a, b, c) for (int i = a; i < b; i += c)
#define brep(i, a, b, c) for (int i = a; i > b; i -= c)
#define tc(t)                                                                  \\
  int t;                                                                       \\
  cin >> t;                                                                    \\
  while (t--)
#define sz(v) int((v).size())
#define pb push_back

using namespace std;

int main() {

#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif

  IOS;

  string s;
  cin >> s;

  if (s[2] == s[3] && s[4] == s[5]) {
    cout << "Yes";
  } else {
    cout << "No";
  }

  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {
  string s;
  cin >> s;
  if (s.at(2) == s.at(3) && s.at(4) == s.at(5)) {
    cout << "Yes";
  } else {
    cout << "No";
  }
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {
  string s;
  cin >> s;
  if (s.at(3) == s.at(4) && s.at(5) == s.at(6)) {
    cout << "Yes";
  } else {
    cout << "No";
  }
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  if (s.at(2) == s.at(3) && s.at(4) == s.at(5))
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
  return 0;
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  if (s.at(3) == s.at(4) && s.at(5) == s.at(6))
    cout << "Yes" << endl;
  else
    cout << "No" << endl;

  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

#define ll long long
#define pb push_back
#define mp make_pair
#define ff first
#define ss second
#define MOD 1000000007

void func() {

  string s;
  cin >> s;

  if (s[0] != s[1] && s[2] == s[3] && s[4] == s[5])
    cout << "Yes" << endl;
  else
    cout << "No" << endl;
}

int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);

  /* #ifndef ONLINE_JUDGE
   freopen("input.txt", "r" , stdin);
   freopen("output.txt", "w" , stdout);
   #endif*/

  ll t = 1;
  // cin>>t;
  while (t--)
    func();
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

#define ll long long
#define pb push_back
#define mp make_pair
#define ff first
#define ss second
#define MOD 1000000007

void func() {

  string s;
  cin >> s;

  if (s[0] != s[1] && s[2] == s[3] && s[4] == s[5])
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
}

int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);

#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif

  ll t = 1;
  // cin>>t;
  while (t--)
    func();
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

/*   CREATED BY
       STREAM_CIPHER
       28-03-2020
  */
#include <bits/stdc++.h>
#include <cstdio>
using namespace std;
typedef long long int ll;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);

  string a;
  cin >> a;
  if (a[2] == a[3] && a[4] == a[5])
    cout << "Yes\\n";
  else
    cout << "No\\n";
}

Error: WA

Fixed submission:

/*   CREATED BY
       STREAM_CIPHER
       28-03-2020
  */
#include <bits/stdc++.h>
#include <cstdio>
using namespace std;
typedef long long int ll;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif
  string a;
  cin >> a;
  if (a[2] == a[3] && a[4] == a[5])
    cout << "Yes\\n";
  else
    cout << "No\\n";
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  if (S.at(2) == S.at(3) && S.at(4) == S.at(5)) {
    cout << "Yes";
  } else {
    cout << "No";
  }
}

Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  if (S.at(3) == S.at(4) && S.at(5) == S.at(6)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
#define int long long
#define MOD 1000000007
#define MAX 100005
#define pb push_back
#define mp make_pair
#define pii pair<int, int>
#define mii map<int, int>
#define vi vector<int>
#define ff first
#define ss second
#define T                                                                      \\
  int t;                                                                       \\
  cin >> t;                                                                    \\
  while (t--)
#define loop(i, a, b) for (int i = a; i < b; i++)
#define umi unordered_map<int, int>
#define maxheap priority_queue<int>
#define minheap priority_queue<int, vector<int>, greater<int>>
#define inp(n) for (int i = 0; i < n; i++)
#define N 200005
#define mxN 2000005
#define all(v) v.begin(), v.end()
#define lb(v, val) (int)(lower_bound(v.begin(), v.end(), val) - v.begin())
#define ub(v, val) (int)(upper_bound(v.begin(), v.end(), val) - v.begin())
using namespace std;
using namespace std::chrono;

int v[N];

void solve() {
  string s;
  cin >> s;
  if (s.length() < 6) {
    cout << "Yes";
  } else {
    if (s[2] == s[3] && s[4] == s[5])
      cout << "Yes";
    else
      cout << "No";
  }
}

signed main() {
  /*#ifndef ONLINE_JUDGE
          freopen("input.txt","r",stdin);
          freopen("output.txt","w",stdout);
  #endif   */
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);

  int t = 1, tt = 0;
  // cin >> t;
  while (t--) {
    tt++;
    // cout << "Case #" <<tt<<": ";
    solve();
    cout << "\\n";
  }
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
#define int long long
#define MOD 1000000007
#define MAX 100005
#define pb push_back
#define mp make_pair
#define pii pair<int, int>
#define mii map<int, int>
#define vi vector<int>
#define ff first
#define ss second
#define T                                                                      \\
  int t;                                                                       \\
  cin >> t;                                                                    \\
  while (t--)
#define loop(i, a, b) for (int i = a; i < b; i++)
#define umi unordered_map<int, int>
#define maxheap priority_queue<int>
#define minheap priority_queue<int, vector<int>, greater<int>>
#define inp(n) for (int i = 0; i < n; i++)
#define N 200005
#define mxN 2000005
#define all(v) v.begin(), v.end()
#define lb(v, val) (int)(lower_bound(v.begin(), v.end(), val) - v.begin())
#define ub(v, val) (int)(upper_bound(v.begin(), v.end(), val) - v.begin())
using namespace std;
using namespace std::chrono;

int v[N];

void solve() {
  string s;
  cin >> s;
  if (s.length() < 6) {
    cout << "Yes";
  } else {
    if (s[2] == s[3] && s[4] == s[5])
      cout << "Yes";
    else
      cout << "No";
  }
}

signed main() {
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
  freopen("output.txt", "w", stdout);
#endif
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);

  int t = 1, tt = 0;
  // cin >> t;
  while (t--) {
    tt++;
    // cout << "Case #" <<tt<<": ";
    solve();
    cout << "\\n";
  }
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <cstdio>
#include <string>
using namespace std;

int main() {
  char s[6];

  scanf("%s", s);

  if (s[2] == s[3] && s[4] == s[5]) {
    printf("Yes");
    fflush(stdout);
  } else {
    printf("No");
    fflush(stdout);
  }

  return 0;
}


Error: -6
terminate called after throwing an instance of 'std::out_of_range'
  what():  basic_string::at: __n (which is 3) >= this->size() (which is 0)


Fixed submission:

#include <cstdio>
#include <string>
using namespace std;

int main() {
  string s;

  scanf("%s", &s);

  if (s.at(3) == s.at(4) && s.at(5) == s.at(6)) {
    printf("Yes");
    fflush(stdout);
  } else {
    printf("No");
    fflush(stdout);
  }

  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  int count = 0;
  if (S.at(2) == S.at(3) && S.at(4) == S.at(5)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  if (S.at(3) == S.at(4) && S.at(5) == S.at(6)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {
  string s;
  cin >> s;

  if (s[2] == s[3] && s[4] == s[5])
    cout << "Yes\\n";
  else
    cout << "No\\n";
}

Error: WA

Fixed submission:

#include <stdio.h>
int main() {
  int i;
  char S[6];
  scanf("%s", S);

  if (S[2] == S[3] && S[4] == S[5])
    printf("Yes");
  else
    printf("No");
  return 0;
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  if (S.at(2) == S.at(3) && S.at(4) == S.at(5)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}


Error: WA

Fixed submission:

#include <bits/stdc++.h>
using namespace std;

int main() {
  string S;
  cin >> S;
  if (S.at(3) == S.at(4) && S.at(5) == S.at(6)) {
    cout << "Yes" << endl;
  } else {
    cout << "No" << endl;
  }
}
Problem p02723 (C++) — buggy submission, verdict: Runtime Error

/*
  In the name of ALLAH
  Author : Raashid Anwar
*/

#include <bits/stdc++.h>
using namespace std;

#define int int64_t
const int M = 1000000007;

int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  // #ifndef ONLINE_JUDGE
  // freopen("input.txt","r",stdin);
  // #endif
  string s;
  cin >> s;
  if (s[2] == s[3] && s[4] == s[5])
    cout << "Yes\\n";
  else
    cout << "No\\n";
}

Error: WA

Fixed submission:

/*
  In the name of ALLAH
  Author : Raashid Anwar
*/

#include <bits/stdc++.h>
using namespace std;

#define int int64_t
const int M = 1000000007;

int32_t main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
#ifndef ONLINE_JUDGE
  freopen("input.txt", "r", stdin);
#endif
  string s;
  cin >> s;
  if (s[2] == s[3] && s[4] == s[5])
    cout << "Yes\\n";
  else
    cout << "No\\n";
}