#include <bits/stdc++.h>
using namespace std;
int solve() {
  long long int n, h, c0, c1, zero = 0, one = 0;
  cin >> n >> c0 >> c1 >> h;
  string s;
  cin >> s;
  for (long long int i = 0; i < n; i++) {
    if (s[i] == '0') zero++;
    if (s[i] == '1') one++;
  }
  cout << min(c0 * zero + c1 * one, min(c0 * n + h * one, c1 * n + h * zero));
  cout << endl;
  return 0;
}
int main() {
  long long int t;
  cin >> t;
  while (t--) {
    solve();
  }
  return 0;
}
