#include <bits/stdc++.h>
using namespace std;
const int maxN = 200 + 7;
int maxx[maxN];
int main() {
  int T;
  cin >> T;
  while (T--) {
    int n, k;
    cin >> n >> k;
    memset(maxx, 0x3f, sizeof(maxx));
    for (int i = 1; i <= k; ++i) {
      int x;
      cin >> x;
      for (int i = 1; i <= n; ++i) maxx[i] = min(maxx[i], abs(x - i) + 1);
    }
    int ans = 0;
    for (int i = 1; i <= n; ++i) ans = max(ans, maxx[i]);
    printf("%d\n", ans);
  }
  return 0;
}
