#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, b, d;
  cin >> n >> b >> d;
  int sum = 0, counter = 0;
  for (int i = 0; i < n; i++) {
    int temp;
    cin >> temp;
    if (temp <= b) sum += temp;
    if (sum > d) {
      counter++;
      sum = 0;
    }
  }
  cout << counter << "\n";
}
