#include <bits/stdc++.h>
using namespace std;
int main() {
  long long int t;
  cin >> t;
  while (t--) {
    unsigned long long int n, a, b;
    cin >> n >> a >> b;
    unsigned long long int cateDe1 = n * a;
    unsigned long long int ans = 0;
    unsigned long long int cateDe2 = n / 2 * b;
    if (n % 2 == 1) {
      cateDe2 += a;
    }
    if (cateDe1 < cateDe2)
      ans = cateDe1;
    else
      ans = cateDe2;
    cout << ans << endl;
  }
}
