#include <bits/stdc++.h>
#include <ext/pb_ds/assoc_container.hpp>
#include <ext/pb_ds/tree_policy.hpp>
using namespace __gnu_pbds;
using namespace std;
#define double long double
#define pb push_back
#define all(x) x.begin(),x.end()
#define rall(x) x.rbegin(),x.rend()
#define int long long
#define f first
#define s second
template<class T>bool umax(T &a,T b){if(a<b){a=b;return true;}return false;}
template<class T>bool umin(T &a,T b){if(b<a){a=b;return true;}return false;}
typedef tree<int, null_type, less_equal<int>, rb_tree_tag,
	tree_order_statistics_node_update> ordered_set;
const int mod= 1e9 +7;
const int N=1e5*4;

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

char a[12][12];
int vis[12][12];

void solve(){
	
	cout<<setprecision(8	);
	int n,m;
	cin>>n>>m;
	double k;
	cin>>k;
	vector<pair<double,double>> a;
	vector<double> b;
	for(int i = 0;i < n;i++){
		double d;
		double w;
		cin>>d>>w;
		a.pb({d,w});
		b.pb(d);
	}
	sort(all(a));
	sort(all(b));
	double ans[n + 1] {};
	for(int i = 0;i < n;i++){
		if(i == 0){
			ans[i ] = a[i].s * k;
		} else{
			ans[i] = (ans[i - 1]);
//			ans[i] *= (1 - k);
			ans[i] *= (  binpow(1 - k,(a[i].f - a[i - 1].f )));
//			ans[i] *= (1 - k);
			ans[i] += a[i].s * k;
		}
	}
	vector<double> v;
	for(int i = 0;i < m;i++){
		int c;
		cin>>c;
		int h = upper_bound(all(b),c) - b.begin();
		if(b[h] > c){
			h--;
		}
		if(h == -1){
			v.pb(0);
		} else{
			if(b[h] == c){
				v.pb(ans[h]);
			} else
				v.pb((ans[h] * ( binpow(1 - k,(c - b[h])))));
		}
	}
	for(auto i : v){
		cout<<i<<" ";
	}


}

 signed main()
{
//	freopen("seq.in", "r", stdin);
//  freopen("seq.out", "w", stdout);
	ios_base::sync_with_stdio(0);cin.tie(NULL);cout.tie(NULL);
	int cnt=0;
	int tt=1;
//	cin>>tt;
	while(tt--)solve();

}


