import java.util.Scanner; public class Highway { public static void main(String[] args) { Scanner scanner = new Scanner(System.in); String S = scanner.nextLine(); String[] strArray = S.split(""); int number = 1; if (strArray.length == 0) { System.out.println(number); return; } for (String s : strArray) { if (s.equals("L")) { number = number * 2; } if (s.equals("R")) { number = number * 2 + 1; } } System.out.println(number); } }