import java.io.*; import java.util.*; public class Main_yukicoder495 { private static Scanner sc; private static Printer pr; private static void solve() { char[] s = sc.next().toCharArray(); int n = s.length; int l = 0; int r = 0; for (int i = 0; i < n / 5; i++) { if (s[5 * i + 1] == '*') { r++; } else { l++; } } pr.printf("%d %d\n", l, r); } // --------------------------------------------------- public static void main(String[] args) { sc = new Scanner(System.in); pr = new Printer(System.out); solve(); pr.close(); sc.close(); } private static class Printer extends PrintWriter { Printer(PrintStream out) { super(out); } } }