#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, b, d;
  cin >> n >> b >> d;
  int ans = 0;
  int x = 0;
  int a;
  while (n--) {
    cin >> a;
    if (a > b) {
      continue;
    }
    x = x + a;
    if (x > d) {
      x = 0;
      ans++;
    }
  }
  cout << ans;
}
