Submission #3557548
Source Code Expand
#include <iostream> #include <string> using namespace std; #define rep(i,n) for(int i=0;i<n;i++) int n, a, b; string s[10010], t, x, y; int main() { cin >> n; rep(i, n)cin >> s[i]; cin >> t; rep(i, n) { x = y = s[i]; rep(j, x.size()) { if (x[j] == '?')x[j] = 'a'; if (y[j] == '?')y[j] = 'z'; } if (t < x)b++; if (t > y)a++; } for (int i = a + 1;i <= n - b + 1;i++) { if (i == n - b + 1)cout << i << endl; else cout << i << " "; } getchar();getchar(); }
Submission Info
Submission Time | |
---|---|
Task | A - Atcoder Handles |
User | anmichi |
Language | C++14 (GCC 5.4.1) |
Score | 250 |
Code Size | 504 Byte |
Status | AC |
Exec Time | 10 ms |
Memory | 896 KB |
Judge Result
Set Name | Subtask1 | Subtask2 | ||||
---|---|---|---|---|---|---|
Score / Max Score | 130 / 130 | 120 / 120 | ||||
Status |
|
|
Set Name | Test Cases |
---|---|
Subtask1 | sub1_in1.txt, sub1_in2.txt, sub1_in3.txt |
Subtask2 | sub1_in1.txt, sub1_in2.txt, sub1_in3.txt, sub2_in1.txt, sub2_in2.txt, sub2_in3.txt |
Case Name | Status | Exec Time | Memory |
---|---|---|---|
sub1_in1.txt | AC | 1 ms | 384 KB |
sub1_in2.txt | AC | 2 ms | 384 KB |
sub1_in3.txt | AC | 2 ms | 384 KB |
sub2_in1.txt | AC | 2 ms | 384 KB |
sub2_in2.txt | AC | 6 ms | 640 KB |
sub2_in3.txt | AC | 10 ms | 896 KB |