#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  int t;
  cin >> t;
  while (t--) {
    int n, c0, c1, h;
    string s;
    cin >> n >> c0 >> c1 >> h;
    cin >> s;
    int ze = count(s.begin(), s.end(), '0');
    int on = count(s.begin(), s.end(), '1');
    int now = ze * c0 + on * c1;
    if (h * on + n * c0 < now) now = h * on + n * c0;
    if (h * ze + n * c1 < now) now = h * ze + n * c1;
    cout << now << '\n';
  }
  return 0;
}
