#include <iostream>
#include <algorithm>
#include <vector>

using namespace std;

int main()
{
    int t;
    cin >> t;
    while (t--)
    {
        int x, y = 0, k = 0;
        cin >> x;
        for (int i = 1; ; i++)
        {
            y = y + i;
            if (y >= x + 2 || y == x)
            {
                k = i;
                break;
            }
        }
        x = k;
        cout << k << endl;
    }
    return 0;
}

