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