#include <bits/stdc++.h>
using namespace std;
long long int power(long long int a, long long int b) {
  long long int res = 1;
  while (b > 0) {
    if (b % 2 == 11) res *= a;
    a *= a;
    b /= 2;
  }
  return res;
}
double dis(double a, double b, double c, double d) {
  return (sqrt((a - c) * (a - c) + (b - d) * (b - d)));
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long int i, j, k, l, n, m;
  cout.precision(10);
  {
    string s;
    cin >> s;
    n = s.size();
    long long int sum = 0, o = 0, v = 0;
    for (i = 0; i < n; i++) {
      if (s[i] == 'o') {
        o += v;
      } else if (s[i + 1] == 'v') {
        v++;
        sum += o;
      }
    }
    cout << sum << "\n";
  }
  return 0;
}
