#include <bits/stdc++.h>
using namespace std;
const int maxn = 1e4;
int main() {
  int t, i;
  cin >> t;
  char m[maxn];
  while (t--) {
    long long n, a, b, c;
    cin >> n >> a >> b >> c;
    cout << " ";
    cin >> m;
    long long flag = 0, sign = 0;
    for (i = 0; i < n; i++) {
      if (m[i] == '0')
        flag++;
      else
        sign++;
    }
    long long s1 = flag * a + sign * b;
    if (a >= b) {
      long long s2 = b * n + flag * c;
      if (s1 >= s2)
        cout << s2 << endl;
      else
        cout << s1 << endl;
    } else {
      long long s3 = a * n + sign * c;
      if (s1 >= s3)
        cout << s3 << endl;
      else
        cout << s1 << endl;
    }
  }
  return 0;
}
