#include using namespace std; int main() { cin.tie(0); ios::sync_with_stdio(false); char s[30]; cin >> s; int RoNum = 1; for (int i = 0; s[i] != '\0'; i++){ if (s[i] == 'L') RoNum *= 2; else RoNum = (RoNum * 2) + 1; } cout << RoNum << endl; }