ll a,b,c,d,e,A,B,C,D,E,i;{for(;~(i=getchar());)i&1?(e+=d,E+=D):i&4?(c+=b,b=a,D+=C,C=B,a=B=0):i&2?(d+=c,B+=A,c=A=0):++a+A++;wtSp(e,E);}