結果

問題 No.495 (^^*) Easy
ユーザー hotaka0213hotaka0213
提出日時 2019-05-01 15:39:07
言語 C++11
(gcc 11.4.0)
結果
RE  
実行時間 -
コード長 307 bytes
コンパイル時間 920 ms
コンパイル使用メモリ 51,096 KB
実行使用メモリ 4,384 KB
最終ジャッジ日時 2023-08-30 04:24:28
合計ジャッジ時間 2,129 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 RE -
testcase_01 RE -
testcase_02 AC 2 ms
4,380 KB
testcase_03 RE -
testcase_04 RE -
testcase_05 RE -
testcase_06 RE -
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <iostream>
#include <string>
using namespace std;
int main(){
	string S;
	cin>>S;
	int x=0,y=0,right=0,left=0;
	while(x==0){
		if(S[y]=='('){
			y++;
		}else if(S[y]=='#'){
			x=1;
		}else if(S[y]=='^'){
			left++;
			y+=5;
		}else{
			right++;
			y+=5;
		}
	}
	cout<<right<<" "<<left;
return 0;
}
0