func_code_string: #include <bits/stdc++.h>   using namespace std;   long long n, A, cf, cm, m;   long long L, ans[100005], f, ansA, ansL;   long long s[100005];   struct data {     long long id, v;   } a[100005];   bool cmp(data a, data b) { return a.v < b.v || a.v == b.v && a.id < b.id; }   long long findL(long long m, long long R) {     long long l = 0, r = A, ans = 0;     while (l <= r) {       long long mid = (l + r) >> 1;       int p = lower_bound(a + 1, a + n + 1, (data){0, mid}, cmp) - a - 1;       if (p > R) p = R;       if (p * mid - s[p] <= m) {         ans = mid;         l = mid + 1;       } else         r = mid - 1;     }     return ans;   }   void init() {     cin >> n >> A >> cf >> cm >> m;     for (int i = 1; i <= n; i++) {       cin >> a[i].v;       a[i].id = i;     }     sort(a + 1, a + n + 1, cmp);     for (int i = 1; i <= n; i++) {       s[i] = s[i - 1] + a[i].v;     }     for (int i = 0; i <= n; i++) {       long long p = A * i - s[n] + s[n - i];       if (p <= m) {         L = findL(m - p, n - i);         if (cm * L + cf * i > f) {           f = cm * L + cf * i;           ansA = i;           ansL = L;         }       }     }     cout << f << endl;     for (int j = 1; j <= n; j++) {       if (j > n - ansA) {         ans[a[j].id] = A;       } else if (a[j].v <= ansL) {         ans[a[j].id] = ansL;       } else         ans[a[j].id] = a[j].v;     }     for (int i = 1; i <= n; i++) {       cout << ans[i] <<    ;     }   }   int main() {     init();     return 0;   }   