Let's call an array a consisting of n positive (greater than 0) integers beautiful if the following condition is held for every i from 1 to n: either a_i = 1, or at least one of the numbers a_i - 1 and a_i - 2 exists in the array as well.

For example: 

  * the array [5, 3, 1] is beautiful: for a_1, the number a_1 - 2 = 3 exists in the array; for a_2, the number a_2 - 2 = 1 exists in the array; for a_3, the condition a_3 = 1 holds; 
  * the array [1, 2, 2, 2, 2] is beautiful: for a_1, the condition a_1 = 1 holds; for every other number a_i, the number a_i - 1 = 1 exists in the array; 
  * the array [1, 4] is not beautiful: for a_2, neither a_2 - 2 = 2 nor a_2 - 1 = 3 exists in the array, and a_2 ≠ 1; 
  * the array [2] is not beautiful: for a_1, neither a_1 - 1 = 1 nor a_1 - 2 = 0 exists in the array, and a_1 ≠ 1; 
  * the array [2, 1, 3] is beautiful: for a_1, the number a_1 - 1 = 1 exists in the array; for a_2, the condition a_2 = 1 holds; for a_3, the number a_3 - 2 = 1 exists in the array. 



You are given a positive integer s. Find the minimum possible size of a beautiful array with the sum of elements equal to s.

Input

The first line contains one integer t (1 ≤ t ≤ 5000) — the number of test cases.

Then t lines follow, the i-th line contains one integer s (1 ≤ s ≤ 5000) for the i-th test case.

Output

Print t integers, the i-th integer should be the answer for the i-th testcase: the minimum possible size of a beautiful array with the sum of elements equal to s.

Example

Input


4
1
8
7
42


Output


1
3
3
7

Note

Consider the example test:

  1. in the first test case, the array [1] meets all conditions; 
  2. in the second test case, the array [3, 4, 1] meets all conditions; 
  3. in the third test case, the array [1, 2, 4] meets all conditions; 
  4. in the fourth test case, the array [1, 4, 6, 8, 10, 2, 11] meets all conditions. 
/*
Practice Karni hai !!!!!!
*/
#include <bits/stdc++.h>

#define fastio                        \
    ios_base::sync_with_stdio(false); \
    cin.tie(NULL)
#define endl "\n"
#define llu unsigned long long int
#define ll long long int
#define gcd(a, b) __gcd(a, b)
#define lcm(a, b) a * b / __gcd(a, b)
#define pb push_back
#define ins insert
#define fr first
#define sc second
#define all(x) x.begin(), x.end()
using namespace std;
#ifndef ONLINE_JUDGE
#define deb(x) cerr << #x << " "; __print(x); cerr << "\n";
#else
#define deb(x)
#endif
template <typename T> void sort    (vector<T>& v) {std::sort(v.begin(), v.end());}
template <typename T> void sortbig (vector<T>& v) {std::sort(v.begin(), v.end(), greater<T>());}
void __print(int x) {cerr << x << " ";}
void __print(ll x) {cerr << x << " ";}
void __print(llu x) {cerr << x << " ";}
void __print(char x) {cerr << x << " ";}
void __print(bool x) {cerr << x << " ";}
void __print(string x) {cerr << x << " ";}
template <class T1, class T2> void __print(vector<pair<T1, T2>> x) {cerr << "[ "; for (pair<T1, T2> z : x)cerr << "{" << z.fr << ", " << z.sc << "}" << " "; cerr << "]";}
template <class T> void __print(vector<T> x) {cerr << "[ "; for (T i : x) __print(i); cerr << "]";}
template <class T> void __print(set<T> x) {cerr << "[ "; for (T i : x) __print(i); cerr << "]";}
template <class T> void __print(map<T, T> x) {for (pair<T, T>  i : x) {cerr << i.fr << " " << i.sc << "\n";}}
int main()
{
#ifndef ONLINE_JUDGE
    freopen("input.txt", "r", stdin);
    freopen("output.txt", "w", stdout);
#endif
#ifndef ONLINE_JUDGE
    freopen("debug.txt", "w", stderr);
#endif
    fastio;
    int t = 1;
    cin >> t;
    while (t--)
    {
        ll n;
        cin >> n;
        ll x = 1;
        while (x * x < n)
            x++;
        cout << x << "\n";
    }
    return 0;
}
// 1 = dono
// 2 = pehela
// 3 = doosra
// 4 = koi nhi
/* stuff you should look for
* int overflow, array bounds
* special cases (n=1?)
* do smth instead of nothing and stay organized
* WRITE STUFF DOWN
* DON'T GET STUCK ON ONE APPROACH
*/