#include <iostream>
#include <vector>

using namespace std;

int collect_aura(vector<int> ar, int k, int start, int max_c);

int main()
{
    int aura = 0;
    int n;
    int k;
    int x;

    vector<int> ar;
    cin >> n;
    cin >> k;
    cin >> x;

    for(int i = 0; i < n; i++)
    {
        int tmp;
        cin >> tmp;
        ar.push_back(tmp);
    }

    for(int i = 0; i < n - k + 1; i++)
    {
        int ra = collect_aura(ar, k, i, x);
        cout << ra << " ";
    }
    cout << endl;


    return 0;
}

int collect_aura(vector<int> ar, int k, int start, int max_c)
{
    int c = 1;
    int aura = 0;
    for(int i = start; i < k + start; i++)
    {
        aura += ar[i] * c;
        if(c < max_c)
            c++;
    }
    return aura;
}