#include <bits/stdc++.h>
using namespace std;
int n, m;
long long res1, res2, f[5][5];
string s;
int main() {
  std::ios::sync_with_stdio(false);
  cin >> s;
  n = s.size();
  for (int i = 0; i < (n); i++) {
    f[s[i] - 'a'][i % 2]++;
    res1 += f[s[i] - 'a'][1 - (i % 2)];
    res2 += f[s[i] - 'a'][i % 2];
  }
  cout << res1 << ' ' << res2 << endl;
  ;
  return 0;
}
