#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, b, d;
  cin >> n >> b >> d;
  int waste = 0, count = 0;
  for (int i = 0; i < n; i++) {
    int a;
    cin >> a;
    if (a <= b) waste += a;
    if (waste > d) waste = 0, count++;
  }
  cout << count << endl;
}
