while(L=readline())print(L[4]?L.replace(/^(l|(.))(i|(.))|(u|(.))(x|(.))$|n/gi,'$2$4$6$8').length:-1)