#ifdef LOCAL
    #define _GLIBCXX_DEBUG
#endif // LOCAL

#include <iostream>
#include <vector>
#include <algorithm>
#include <cmath>
#include <unordered_map>
#include <map>
#include <set>
#include <unordered_set>
#include <bitset>
#include <queue>
#include <iomanip>
#include <iterator>
#include <fstream>
#include <cstdlib>
#include <random>
#include <climits>
#include <chrono>

using namespace std;

#define int long long
#define f first
#define s second
#define fi first
#define se second
#define p_b push_back
#define e_b emplace_back
#define pw(x) (1LL<<((int)x))
#define sz(x) (ll)x.size()
#define m_p make_pair
#define all(x) x.begin(),x.end()
#define rall(x) x.rbegin(),x.rend()

using ll = long long;
using ul = unsigned long long;
using pii = pair<int, int>;
using pll = pair<ll, ll>;
using ld = long double;

const ll N = 2e5 + 5, mod = 1e9+7;

template<class T> inline T sqr(T x) {return x * x;}
template<class T> inline void amin(T &a, T b) {a = a < b ? a : b;}
template<class T> inline void amax(T &a, T b) {a = a > b ? a : b;}
template<class T> inline void smod(T &a, T b) {a = a + b >= mod ? a + b - mod : a + b;}
template<class T> inline void dmod(T &a, T b) {a = a - b >= 0 ? a - b : a - b + mod;}

mt19937 rnd(time(0));

const long double ex = 1e-9;

int n, m;
long double r;
vector<pair<int, int> > a;
vector<long double> b;

long double binpow(long double a, int b) {
    if (b == 0)
        return 1;
    long double x = binpow(a, b / 2);
    if (x < ex)
        x = 0;
    if (b % 2 == 0)
        return x * x;
    return x * x * a;
}

long double wait(long double val, int days) {
    return val * binpow(1 - r, days);
}

void solve() {
    cin >> n >> m;
    cin >> r;
    a.resize(n);
    for (int i = 0; i < n; i ++)
        cin >> a[i].fi >> a[i].se;
    a.push_back({0, 0});

    sort(all(a));
    b.resize(n + 1);
    b[0] = 0;
    for (int i = 1; i <= n; i ++) {
        int days = a[i].fi - a[i - 1].fi;
        b[i] = wait(b[i - 1], days) + a[i].second * r;
    }

    vector<int> ddd(n + 1);
    for (int i = 0; i <= n; i ++)
        ddd[i] = a[i].fi;

    cout << fixed << setprecision(8);
    for (int i = 0 ; i < m; i ++) {
        int need;
        cin >> need;
        int ind = lower_bound(all(ddd), need) - ddd.begin();
        if (ind == sz(ddd) || ddd[ind] > need)
            ind --;
        cout << wait(b[ind], need - ddd[ind]) << ' ';
    }

//    for (int i = 0; i <= n; i ++)
//        cout << b[i] << ' ';
}

main() {
    #ifdef LOCAL
//        freopen("input.txt", "r", stdin);
//        freopen("output.txt", "w", stdout);
    #else
        ios_base::sync_with_stdio(0);
        cin.tie(0);
        cout.tie(0);
    #endif // LOCAL
    int t = 1;
//    cin >> t;
    while (t--) {
        solve();
    }
    #ifdef LOCAL
        cout << "\n\n===\nTime : " << (long double)clock() / CLOCKS_PER_SEC << '\n';
    #endif // LOCAL
}
