#include <bits/stdc++.h>
using namespace std;
const long long int INF = 0x3f3f3f3f;
const long long int maxn = 1e6 + 1;
const double eps = 1e-4;
int main(void) {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.precision(10);
  cout << fixed;
  long long int n, p1, p2, p3, t1, t2;
  cin >> n >> p1 >> p2 >> p3 >> t1 >> t2;
  pair<long long, long long> arr[n];
  long long int sol = 0;
  for (long long int i = 0; i <= n - 1; i += 1) {
    cin >> arr[i].first >> arr[i].second;
    sol += p1 * (arr[i].second - arr[i].first);
  }
  for (long long int i = 0; i <= n - 2; i += 1) {
    long long int temp = arr[i + 1].first - arr[i].second;
    if (temp >= t1 + t2)
      sol += t1 * p1 + t2 * p2 + (temp - (t1 + t2)) * p3;
    else if (temp >= t1)
      sol += t1 * p1 + (temp - t1) * p2;
    else if (temp < t1)
      sol += temp * p1;
  }
  cout << sol << "\n";
  return 0;
}
