#include<bits/stdc++.h>
using namespace std;
#define F first
#define S second
#define ll long long
#define sz(s) (int)s.size()
#define in insert
#define pii pair<int, int>
#define pb push_back
#define mp make_pair
#define double long double

const int N = 1e5+123;

int n,m;
double r;
pair <int, int> a[N];
map <int, double> ans;
set <int> st;

double bp(double x, int y){
    if(y == 0){
        return 1.0;
    }

    if(y%2 == 0){
        double b = bp(x, y/2);
        return b*b;
    } else {
        return x*bp(x,y-1);
    }
}

int main(){
    cin >> n >> m >> r;
    for(int i = 1; i <= n; ++i){
        cin >> a[i].F >> a[i].S;
        st.insert(a[i].F);
    }

    sort(a+1,a+n+1);
    for(int i = 1; i <= n; ++i){
        ans[a[i].F] = ans[a[i-1].F]*bp(1.0-r, a[i].F-a[i-1].F) + a[i].S*r;
        //cout << ans[a[i].F] << ' ';
    }

    for(int i = 1; i <= m; ++i){
        int q;
        cin >> q;
        auto it = st.upper_bound(q);
        if(it==st.begin()){
            cout<<0<<" ";
            continue;
        }

        it--;
        double res = ans[*it]*bp(1.0-r, q-*it);
        cout << fixed << setprecision(9) << res << ' ';
    }
}