#include <bits/stdc++.h>
using namespace std;
int main() {
  int oranges, maxi, d;
  cin >> oranges >> maxi >> d;
  long long counter = 0, c = 0;
  for (int i = 0; i < oranges; i++) {
    int o;
    cin >> o;
    if (o <= maxi) {
      counter += o;
      if (counter > d) {
        c++;
        counter = 0;
      }
    }
  }
  cout << c << endl;
  return 0;
}
