Submission #00822
ソースコード
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | #include<bits/stdc++.h> using namespace std; const int INF = 1 << 30; int n, m; string str[100], tate[100]; int main() { cin >> n >> m; for ( int i = 0; i < n; i++) { cin >> str[i]; } for ( int j = 0; j < m; j++) { tate[j] = "" ; for ( int i = 0; i < n; i++) tate[j] += str[i][j]; } bool Find = false ; for ( int i = 0; i < n; i++) { Find |= str[i].find( "helloworld" ) != string::npos; Find |= str[i].find( "dlrowolleh" ) != string::npos; } for ( int i = 0; i < m; i++) { Find |= tate[i].find( "helloworld" ) != string::npos; Find |= tate[i].find( "dlrowolleh" ) != string::npos; } puts (Find ? "Homono is Criminal" : "NA" ); } |
ステータス
項目 | データ |
---|---|
問題 | 0055 - Hello world Extreme |
ユーザー名 | root |
投稿日時 | 2015-07-22 09:54:21 |
言語 | C++11 |
状態 | Accepted |
得点 | 50 |
ソースコード長 | 687 Byte |
最大実行時間 | 14 ms |
最大メモリ使用量 | 622 KB |
セット
セット | 得点 | Cases | |
---|---|---|---|
1 | ALL | 1 / 1 | * |
テストケース
ファイル名 | 状態 | 実行時間 | メモリ使用量 | # |
---|---|---|---|---|
sample1_in.txt | AC | 11 ms | 548 KB |
1
|
sample2_in.txt | AC | 10 ms | 516 KB |
1
|
sample3_in.txt | AC | 14 ms | 474 KB |
1
|
sample4_in.txt | AC | 10 ms | 546 KB |
1
|
sample5_in.txt | AC | 13 ms | 622 KB |
1
|