# http://chiwawa-star.hatenablog.com/entry/2017/07/12/194636 import sys input = sys.stdin.readline sys.setrecursionlimit(10**6) ############################## S = input().rstrip() ptn = set() def dfs(s, t): # print(s, t) if len(s) == 0: ptn.add(t) return dfs(s[1:], t+s[0]) dfs(s[0:-1], t+s[-1]) return dfs(S, '') print(len(ptn))