#include <iomanip>
#include <iostream>
#include <limits>
#include <vector>
#include <algorithm>
#include <bitset>

#define ins int(1e9 + 1)

using namespace std;

#define inf (long long)1e9
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")
#pragma GCC target("avx2")

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

bool comp(vector<long long> ev1, vector<long long> ev2) {
    if (ev1[0] < ev2[0]) return true;
    if (ev2[0] < ev1[0]) return false;
    if (ev2[1] == -1) return true;
    if (ev1[1] == -1) return false;
}

int main() {
    ios_base::sync_with_stdio(false);
    cin.tie(0);
    long long n, m;
    cin >> n >> m;
    long double r;
    cin >> r;
    vector<vector<long long>> evs;
    for (int i = 0; i < n; ++i) {
        long long d, w;
        cin >> d >> w;
        evs.push_back({d, w});
    }
    for (int i = 0; i < m; ++i) {
        long long q;
        cin >> q;
        evs.push_back({q, -1, i});
    }

    vector<long double> res(m);
    sort(evs.begin(), evs.end(), comp);
    long double ans = 0;
    int prev = 0;
    for (auto ev : evs) {
//        for (auto i : ev) cout << i << " ";
//        cout  << endl;
        if (ev[1] == -1) {
            ans = ans * binpow(1 - r, ev[0] - prev);
            prev = ev[0];
            res[ev[2]] = ans;
        } else {
            ans = ans * (1 - r) + r * ev[1];
            prev = ev[0];
        }
//        cout << ev[0] << " " << ans << endl;
    }

//    cout << fixed();
    for (auto i : res) cout << fixed << setprecision(6) << i << " ";
    return 0;
}
