string = input() croatic = ['c=','c-','d-','lj','nj','s=','z=','dz='] print(len(string)-sum(string.count(c) for c in croatic))