#include <bits/stdc++.h>
using namespace std;
long long N;
vector<long long> vl;
string str;
queue<int> ans;
int main() {
  cin >> str;
  vl.resize(1000001);
  bool first = true;
  long long total = 0;
  for (int i = 0; i < str.size(); i++) {
    if (str[i] == 'v') {
      if (first)
        first = false;
      else
        vl[i]++;
    } else {
      ans.push(i);
      first = true;
    }
    if (i > 0) vl[i] += vl[i - 1];
  }
  total = vl[str.size() - 1];
  long long sum = 0;
  while (!ans.empty()) {
    long long num = ans.front();
    sum += (vl[num] * (total - vl[num]));
    ans.pop();
  }
  cout << sum;
}
