#include <bits/stdc++.h>
using namespace std;
void solve() {
  string s;
  cin >> s;
  long long cw = 0, cwo = 0, cwow = 0;
  for (long long i = 1; i < s.size(); i++) {
    if (s[i] == 'v' && s[i - 1] == 'v') {
      cwow += cwo;
      cw++;
    } else if (s[i] == 'o')
      cwo += cw;
  }
  cout << cwow;
  return;
}
signed main() {
  ios_base::sync_with_stdio(false);
  long long t = 1;
  while (t--) solve();
  return 0;
}
