Submission #51232372


Source Code Expand

#include <bits/stdc++.h>
#ifdef LOCAL
#include "debug.h"
#else
#define debug(...)
#endif
using int64 = long long;
using uint = unsigned int;
using uint64 = unsigned long long;
bool ckmin(auto& a, auto b) { return b < a ? a = b, 1 : 0; }
bool ckmax(auto& a, auto b) { return b > a ? a = b, 1 : 0; }
using namespace std;

int main() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);

  string s;
  cin >> s;
  int cnt = 0;
  for (auto ch : s) {
    if (ch == '|') {
      cnt++;
    } else if (cnt != 1) {
      cout << ch;
    }
  }
  cout << '\n';

  return 0;
}

Submission Info

Submission Time
Task A - Spoiler
User xindubawukong
Language C++ 20 (gcc 12.2)
Score 150
Code Size 597 Byte
Status AC
Exec Time 1 ms
Memory 3596 KiB

Judge Result

Set Name Sample All
Score / Max Score 0 / 0 150 / 150
Status
AC × 3
AC × 14
Set Name Test Cases
Sample sample_01.txt, sample_02.txt, sample_03.txt
All random_01.txt, random_02.txt, random_03.txt, random_04.txt, random_05.txt, random_06.txt, random_07.txt, random_08.txt, random_09.txt, random_10.txt, random_11.txt, sample_01.txt, sample_02.txt, sample_03.txt
Case Name Status Exec Time Memory
random_01.txt AC 1 ms 3360 KiB
random_02.txt AC 1 ms 3468 KiB
random_03.txt AC 1 ms 3460 KiB
random_04.txt AC 1 ms 3384 KiB
random_05.txt AC 1 ms 3476 KiB
random_06.txt AC 1 ms 3392 KiB
random_07.txt AC 1 ms 3472 KiB
random_08.txt AC 1 ms 3476 KiB
random_09.txt AC 1 ms 3384 KiB
random_10.txt AC 1 ms 3380 KiB
random_11.txt AC 1 ms 3392 KiB
sample_01.txt AC 1 ms 3596 KiB
sample_02.txt AC 1 ms 3456 KiB
sample_03.txt AC 1 ms 3588 KiB