結果
| 問題 |
No.495 (^^*) Easy
|
| コンテスト | |
| ユーザー |
nak3
|
| 提出日時 | 2017-03-24 22:34:49 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 4 ms / 2,000 ms |
| コード長 | 428 bytes |
| コンパイル時間 | 1,594 ms |
| コンパイル使用メモリ | 159,780 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-07-06 03:07:01 |
| 合計ジャッジ時間 | 2,062 ms |
|
ジャッジサーバーID (参考情報) |
judge1 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 7 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
#define INF 2000000000
#define MOD 1000000007
typedef long long ll;
typedef pair<int, int> P;
int main()
{
string s;
cin >> s;
int idx = 0;
int l = 0;
int r = 0;
while (true) {
if (s[idx]=='#') {
break;
}
if (s[idx+1]=='*') {
r++;
}
if (s[idx+3]=='*') {
l++;
}
idx += 5;
}
// (^^*)(^^*)(*^^)(*^^)(^^*)(*^^)(*^^)#
cout << l << " " << r << "\n";
}
nak3