import math | |
n = int(input()) | |
i=1 | |
while i<=n: | |
x = int(input()) | |
d = (-1 + math.sqrt(1 + 8 * x)) / 2 | |
print(int(d)) | |
i = i+1 |
Subscribe to:
Post Comments (Atom)
-
Suppose you have 24 and you need to find out all divisors of the number. The normally what we do? We just divide the number from 1 to 24. T...
-
It will be easy to solve the problem if you know about the Nim game. " Nim has been mathematically solved for any number of initial...
-
/*** Md. Namzul Hasan Shahjalal University of Science & Technology,Sylhet. hasan08sust@gmail.com ***/ #include<bits/stdc++.h...
No comments:
Post a Comment