S=input() T=["s","a"] U=["l","o"] cnt1=0 cnt2=0 for i in S: if i in T: cnt1+=1 elif i in U: cnt2+=1 if cnt1==0 or cnt2==0: print(0) else: print(2**(cnt1+cnt2)-2**cnt1-2**cnt2+1)