S=input()
k=0
s=''
ex_s=''
pos=0

for i in range(len(S)+1):
  if pos > i:
    print('i, pos : ',i,pos)
    continue
  if pos > len(S):
    break
    
  for j in range(1,len(S)-i):    
    s=S[i:i+j]    
    print(i,j)
    if ex_s==s:
      print('ex_s, s: ',ex_s,s)
      continue
    else:
      # sが2文字、かつ残りが2文字の場合は詰みなので回避
      if   len(s)==2 and i+j+2==len(S):
        continue
      ex_s=s
      k += 1
      pos = i+j
      print(s,i,j,'ok')
      break;

print(k+1)
  