#include <bits/stdc++.h>
 
#define speed ios_base::sync_with_stdio(0); cin.tie(0); cout.tie(0);
#define file(s) if (fopen(s".in", "r")) freopen(s".in", "r", stdin), freopen(s".out", "w", stdout)
#define all(x) (x).begin(), (x).end()
#define pb push_back
#define sz(x) (int)x.size()
#define F first
#define S second
#define int long long

const int maxn = 2e5+7;
const int inf = 1e18;
const int mod = 1e9+7;
  
using namespace std;

int n, m;
long double r;
pair<int, long double> p[maxn];
long double ans[maxn];
map<int, int> mp;

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

void solve(){
	cin >> n >> m;
	cin >> r;
	for(int i = 1; i <= n; i++){
		cin >> p[i].F >> p[i].S;
		mp[p[i].F] = 1;
	}
	sort(p + 1, p + 1 + n);
	for(int i = 1; i <= n; i++){
		if(i > 1){
			long double cur = ans[p[i - 1].F] * (binpow((1.0 - r), (p[i].F - 1) - p[i - 1].F));
			ans[p[i].F] = cur * (1.0 - r) + p[i].S * r;
		}else{
			ans[p[i].F] = 0.0 * (1.0 - r) + p[i].S * r;
		}
	}
	while(m--){
		int pos;
		cin >> pos;
		if(pos < p[1].F){
			cout << 0 << ' ';
			continue;
		}
		if(mp[pos] == 1){
			cout << ans[pos] << ' ';
			continue;
		}
		int L = 1, R = n, res = 0;
		while(L <= R){
			int md = (L + R) / 2;
			if(p[md].F <= pos){
				res = md;
				L = md + 1;
			}else{
				R = md - 1;
			}
		}
		cout.precision(6);
		long double cur = ans[p[res].F] * (binpow((1.0 - r), pos - p[res].F));
		cout << fixed << (long double)(cur) << ' ';
	}
}
 
signed main(){
    speed
    int test = 1;
    // cin >> test;
    while(test--){
        solve();
    }
}