#include <bits/stdc++.h>
#define int long long
using namespace std;
double bin_pow(double r1,int n){
    if(n==0) return 1;
    if(n==1) return r1;
    if(n%2==0) return bin_pow(r1,n/2) * bin_pow(r1,n/2);
    return bin_pow(r1,n-1)*r1;
}
signed main(){
    ios_base::sync_with_stdio(0),cin.tie(0);
    cout<<fixed<<setprecision(7);
    int n,m;
    cin>>n>>m;
    double r;
    cin>>r;
    double r1=1-r;
    vector <pair<int,int>> a(n);
    for(int i=0;i<n;i++){
        cin>>a[i].first;
        cin>>a[i].second;
    }
    stable_sort(a.begin(),a.end());
    vector <int> a1(n);
    vector <int> a2(n);
    for(int i=0;i<n;i++){
        a1[i]=a[i].first;
        a2[i]=a[i].second;
    }
    vector <double> pref(n);
    pref[0]=a2[0]*r;
    for(int i=1;i<n;i++){
        pref[i]=pref[i-1] * bin_pow(r1,a1[i]-a1[i-1]) + r * a2[i];
    }
    for(int i=0;i<m;i++){
        int q;
        cin>>q;
        int ind=upper_bound(a1.begin(),a1.end(),q)-a1.begin() - 1;
        if(ind<0){
            cout<<0<<" ";
            continue;
        }
        double ans = pref[ind] * bin_pow(r1,q-a1[ind]);
        cout<<ans<<" ";
    }
    return 0;
}
/*
3 3
0.5
2 6
3 8
4 10
1 3 5

5 6
0.3333333
1 27
6 27
3 27
4 27
5 27
1 2 3 4 5 6

1 1
0
1 1000000000
1000000000

*/