#define _CRT_SECURE_NO_WARNINGS
#include <iostream>
#include <bitset>
#include <map>
#include <algorithm>
#include <cmath>
#include <vector>
#define fir first
#define sec second

using ll = long long;
template<typename T>
bool rMin(T& a, const T& b){
    if(b < a){
        a = b;
        return true;
    }
    return false;
}

template<typename T>
bool rMax(T& a, const T& b){
    if(a < b){
        a = b;
        return true;
    }
    return false;
}

using namespace std;

double pow(double a, int p){
    if(p == 0) return 1;
    if((p & 1) == 0){
        double x = pow(a, p >> 1);
        return x * x;
    }
    return a * pow(a, p ^ 1);
}

vector<pair<int, int>> days;
double res[100100];
void solve(){
    int qd, qr, req, a, b;
    double r;
    cin >> qd >> qr >> r;
    days.emplace_back(0, 0);
    for(int i = 1; i <= qd; ++i){
        cin >> a >> b;
        days.emplace_back(a, b);
    }
    days.emplace_back(1000000100, 0);
    sort(days.begin(), days.end());
    for(int i = 1; i <= qd; ++i){
        res[i] = r * days[i].sec + pow(1 - r, days[i].fir - days[i - 1].fir) * res[i - 1];
    }
    while(qr--){
        cin >> req;
        auto s = lower_bound(days.begin(), days.end(), make_pair(req, 1000000100)) - 1;
        cout << pow(1 - r, req - s->fir) * res[s - days.begin()] << ' ';
    }
}

int main(){
#ifdef _DEBUG
    freopen("input.txt", "r", stdin);
    freopen("output.txt", "w", stdout);
#else
    //freopen("input.txt", "r", stdin);
    //freopen("output.txt", "w", stdout);
#endif
    cout.precision(10);
    int t = 1;

    //cin >> t;

    for(int i = 0; i < t; ++i){
        solve();
    }
}