#include <bits/stdc++.h>
using namespace std;
const int maxn = 205;
int n, k;
int x[maxn];
bool check(int t) {
  sort(x, x + k);
  if (x[0] > t) return false;
  for (int i = 1; i < k; i++) {
    if ((t - 1) * 2 < x[i] - x[i - 1] - 1) return false;
  }
  if (x[k - 1] + t - 1 < n) return false;
  return true;
}
int main() {
  int t;
  cin >> t;
  while (t--) {
    cin >> n >> k;
    for (int i = 0; i < k; i++) {
      cin >> x[i];
    }
    int l = 1, r = 300;
    while (l != r) {
      int mid = (l + r) / 2;
      if (check(mid))
        r = mid;
      else
        l = mid + 1;
    }
    cout << l << endl;
  }
}
