結果
問題 | No.104 国道 |
ユーザー |
![]() |
提出日時 | 2015-08-06 00:48:29 |
言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
結果 |
AC
|
実行時間 | 2 ms / 5,000 ms |
コード長 | 604 bytes |
コンパイル時間 | 503 ms |
コンパイル使用メモリ | 72,952 KB |
実行使用メモリ | 5,376 KB |
最終ジャッジ日時 | 2024-07-18 03:36:00 |
合計ジャッジ時間 | 1,140 ms |
ジャッジサーバーID (参考情報) |
judge1 / judge2 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 16 |
ソースコード
#include <cstdio> #include <cstdlib> #include <iostream> #include <string> #include <cmath> #include <algorithm> #include <vector> #include <queue> #include <stack> #include <map> #include <set> #include <cstring> typedef long long ll; using namespace std; #define mod 1000000009 #define INF 1000000000 #define LLINF 2000000000000000000LL #define PI 3.1415926536 #define SIZE 101 int main(){ int ans=1; string S; cin >> S; for(int i=0;i<S.size();i++){ ans*=2; if(S[i]=='R') ans+=1; } printf("%d\n",ans); return 0; }