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