/** Bismillahir Rahmanir Rahim **/
#include <bits/stdc++.h>
using namespace std;
#define ll long long
#define pb push_back
#define pf push_front
#define endl '\n'
#define fi first
#define se second
#define ull unsigned ll
#define Fastio ios::sync_with_stdio(false); cin.tie(0); cout.tie(0);
#define debug(x) cerr << #x << " "<< x << endl

int main()
{
   Fastio;
   int tt, n;
   cin >> tt;
   while (tt--) {
      cin >> n;
      int init = 0, ans;
      for (int i = 1; ; i++) {
         init += i;
         if (init >= n) {
            ans = i;
            break;
         }
      }
      if (init - n == 1) ans++;
      cout << ans << endl;
   }
    
   return 0;
}