#include <bits/stdc++.h>
#pragma GCC optimize("O3")
#pragma GCC optimize("unroll-loops")
using namespace std;
using ll = long long;
using ii = pair<int, int>;
const int N = 5e5 + 5, LG = 19, MOD = 998244353;
const int SQ = 225;
const long double EPS = 1e-7;
int32_t main() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  int t;
  cin >> t;
  while (t--) {
    int n, limit;
    cin >> n >> limit;
    vector<int> v(n + 2);
    for (int i = 1; i < n + 1; i++) cin >> v[i];
    v[n + 1] = limit;
    double lo = 0.0, hi = 1e9;
    for (int j = 0; j < 200; j++) {
      double md = lo + (hi - lo) / 2.0;
      double cur1 = 0.0, curS = 1.0, curTime = 0;
      for (int i = 0; i <= n; i++) {
        if (fabs(v[i + 1] - v[i]) / curS + curTime <= md) {
          curTime += fabs(v[i + 1] - v[i]) / curS;
          cur1 = v[i + 1];
          curS++;
        } else {
          cur1 += (md - curTime) * curS;
          break;
        }
      }
      double cur2 = limit;
      curS = 1.0, curTime = 0.0;
      for (int i = n + 1; i > 0; --i) {
        if (fabs(v[i - 1] - v[i]) / curS + curTime <= md) {
          curTime += fabs(v[i - 1] - v[i]) / curS;
          cur2 = v[i - 1];
          curS++;
        } else {
          cur2 -= (md - curTime) * curS;
          break;
        }
      }
      if (cur1 >= cur2)
        hi = md;
      else
        lo = md;
    }
    cout << fixed << setprecision(6) << lo << '\n';
  }
  return 0;
}
