/**
 *    author  : 𝒌𝒚𝒐𝒎𝒖𝒌𝒚𝒐𝒎𝒖𝒑𝒖𝒓𝒊𝒏
 *    created : 2020-01-26 20:09:22
**/

#include <iostream>
#include <deque>
#include <map>
#include <queue>
#include <set>
#include <stack>
#include <string>
#include <vector>
#include <algorithm>
#include <cmath>
#include <complex>
#include <numeric>
#include <bitset>
#include <cassert>
#include <cctype>
#include <iomanip>
#include <random>
#include <utility>
#include <chrono>

using namespace std;

using int64 = long long;

template<class T> std::ostream& operator<<(std::ostream& os, const std::vector<T>& vec) { os << '{'; size_t n = vec.size(); for (size_t i = 0; i < n; ++i) { os << vec[i]; if (i != n - 1) os << ','; } os << '}'; return os; }
template<class T, class U> std::ostream& operator<<(std::ostream& os, const std::pair<T, U>& p) { return os << '{' << p.first << " " << p.second << '}'; }
template<class T, class U> std::ostream& operator<<(std::ostream& os, const std::map<T, U>& mp) { for (auto it = mp.begin(); it != mp.end(); ++it) { os << '{' << it->first << ':' << it->second << '}'; if (it != --mp.end()) os << ','; } return os; }
template<class T> std::ostream& operator<<(std::ostream& os, const std::set<T>& st) { os << '{'; for (auto it = st.begin(); it != st.end(); ++it) { os << *it; if (it != --st.end()) os << ','; } os << '}'; return os; }
template<class T> std::istream& operator>>(std::istream& is, std::vector<T>& vec) { size_t n = vec.size(); for (size_t i = 0; i < n; ++i) is >> vec[i]; return is; }

#define all(_) begin(_), end(_)
#define rall(_) rbegin(_), rend(_)

#ifdef LOCAL
#define debug(_) cerr << #_ << ": " << (_) << '\n'
#define getchar_unlocked getchar
#else
#define debug(_) 1728
#endif

template<class T> inline void fastin(T &num) {
  bool negative = false;
  T c;
  num = 0;
  c = getchar_unlocked();
  if (c == '-') {
    negative = true;
    c = getchar_unlocked();
  }
  for (; (c > 47 && c < 58); c = getchar_unlocked()) num = (num << 3) + (num << 1) + c - 48;
  if (negative) num *= -1;
}

template <class T>
class FenwickTree {
 public:
  FenwickTree(const std::vector<T>& data) : n_(data.size() + 1), data_(data) {
    Initialize();
  }

  void Add(size_t pos, T value) {
    ++pos;
    while (pos < n_) {
      node_[pos] += value;
      pos += pos & -pos;
    }
  }

  // return sum of [0, i]
  T GetSum(size_t pos) {
    ++pos;
    T sum = 0;
    while (pos > 0) {
      sum += node_[pos];
      pos -= pos & -pos;
    }
    return sum;
  }

  // return sum of [left, rihgt]
  T GetRangeSum(int left, int right) {
    return GetSum(right) - GetSum(left - 1);
  }

  // for range add query
  class RAQ {
   public:
    RAQ(const std::vector<T>& data)
        : n_(data.size()),
          ft1_(FenwickTree<T>(data)),
          ft2_(FenwickTree<T>(data)) {}

    // add value range [left, right)
    void RangeAdd(int left, int right, T value) {
      Add(ft1_, left, right, value);
      Add(ft2_, left, right, -value * static_cast<T>(left - 1));
      Add(ft2_, right, n_, value * static_cast<T>(right - left));
    }

    // get sum of [0, i]
    T GetSum(size_t pos) {
      return ft1_.GetSum(pos) * static_cast<T>(pos) + ft2_.GetSum(pos);
    }

    // get sum of [left, right]
    T GetRangeSum(int left, int right) {
      return GetSum(right) - GetSum(left - 1);
    }

    T operator[](size_t position) { return GetRangeSum(position, position); }

   private:
    size_t n_;
    FenwickTree<T> ft1_;
    FenwickTree<T> ft2_;
    void Add(FenwickTree<T>& ft, int left, int right, T value) {
      ft.Add(left, value);
      ft.Add(right, -value);
    }
  };

 private:
  size_t n_;
  std::vector<T> data_;
  std::vector<T> node_;
  void Initialize() {
    node_.assign(n_ + 1, 0);
    for (size_t i = 0; i < n_ - 1; ++i) Add(i, data_[i]);
  }
};


int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);

  int n; fastin(n);
  int64 d, a; fastin(d); fastin(a);
  vector<pair<int64, int64>> v;
  vector<int64> x(n), h(n);
  for (int i = 0; i < n; ++i) {
    fastin(x[i]); fastin(h[i]);
    v.emplace_back(x[i], h[i]);
  }

  sort(all(x));
  sort(all(v));

  FenwickTree<int64>::RAQ ft(vector<int64>(n + 1, 0LL));

  for (int i = 0; i < n; ++i) {
    ft.RangeAdd(i, i + 1, v[i].second);
  }

  int64 ans = 0;

  for (int i = 0; i < n; ++i) {
    if (ft[i] <= 0LL) continue;
    int64 need = (ft[i] + a - 1LL) / a;
    ans += need;
    int pos = distance(x.begin(), upper_bound(all(x), v[i].first + 2LL * d)) - 1;
    ft.RangeAdd(i, pos + 1, -1 * need * a);
    assert(ft[i] <= 0LL);
  }

  cout << ans << endl;

  return 0;
}

Measured memory_bytes: 15212