#include <bits/stdc++.h>
using namespace std;
signed main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  cout.tie(NULL);
  string s;
  cin >> s;
  long long w = 0, o = 0;
  for (long long i = 0; i < s.length() - 1; i++) {
    if (s[i] == 'v' && s[i + 1] == 'v')
      w++;
    else {
      if (s[i] == 'o') o++;
    }
  }
  if (s[s.length() - 1] == 'o') o++;
  long long x = 0, ans = 0;
  for (long long i = 0; i < s.length() - 1; i++) {
    if (s[i] == 'v' && s[i + 1] == 'v')
      x++;
    else {
      if (s[i] == 'o') {
        ans += x * (w - x);
      }
    }
  }
  cout << ans;
  return 0;
}
