結果
問題 | No.104 国道 |
ユーザー |
|
提出日時 | 2020-03-14 03:57:13 |
言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 3 ms / 5,000 ms |
コード長 | 196 bytes |
コンパイル時間 | 1,990 ms |
コンパイル使用メモリ | 191,500 KB |
最終ジャッジ日時 | 2025-01-09 06:45:30 |
ジャッジサーバーID (参考情報) |
judge1 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 4 |
other | AC * 16 |
ソースコード
#include <bits/stdc++.h>#define rep(i,n) for(int i=0;i<(n);i++)using namespace std;int main(){string s; cin>>s;int p=1;for(char c:s) p=(c=='L'?2*p:2*p+1);cout<<p<<'\n';return 0;}