s=input();a="yuzukizukari" print(*[min(s.count(u)//t.count(u)for u in t)for t in("yu"+a[8:],"a"+a[8:],a[:8])])