#include <bits/stdc++.h>
using namespace std;
int main() {
  int q;
  cin >> q;
  int i;
  for (i = 0; i < q; i++) {
    long long int n, a, b;
    cin >> n >> a >> b;
    long long int sum1 = 0;
    long long int sum2 = 0;
    sum1 = n * a;
    if (n % 2 == 0) {
      sum2 = (n / 2) * b;
    } else {
      sum2 = (n / 2) * b;
      sum2 = sum2 + a;
    }
    if (sum1 < sum2) {
      cout << sum1 << endl;
    } else {
      cout << sum2 << endl;
    }
  }
  return 0;
}
