#include <bits/stdc++.h>
using namespace std;
int d[100005][2];
int main() {
  long long p = 0, ne = 0;
  string s;
  cin >> s;
  int n = s.length();
  for (int i = 0; i < n; i++) {
    d[s[i] - 'a'][i % 2]++;
    p += d[s[i] - 'a'][1 - (i % 2)];
    ne += d[s[i] - 'a'][i % 2];
  }
  cout << p << " " << ne;
}
