#include <bits/stdc++.h>
using namespace std;
string s;
long long a, b, c;
int main() {
  cin >> s;
  for (int i = 1; i < s.size(); i++) {
    if (s[i] == 'o')
      b += a;
    else if (s[i - 1] == 'v') {
      a++;
      c += b;
    }
  }
  cout << c << endl;
}
