#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  vector<long long> arr(s.size());
  long long ans = 0;
  for (long long i = 1; i < s.size(); i++) {
    if (s[i - 1] == 'v' && s[i] == 'v')
      arr[i] = 1 + arr[i - 1];
    else
      arr[i] = arr[i - 1];
  }
  for (long long i = 1; i < s.size(); i++) {
    if (s[i] == 'o') {
      long long left = arr[i - 1];
      long long right = arr[arr.size() - 1] - arr[i];
      ans += left * right;
    }
  }
  cout << ans << endl;
  return 0;
}
