REALNO - Real Numbers
Find whether there exists a pair of real numbers whose sum is in range (1, 2) in an array consisting of real number in the range (0, 2). If there exists such a pair print "found" else print "not found". (Double quotes only for clarity)
Note: all intervals given above are open intervals.
Input
First line is the number of test cases t (t <= 6),
then for each case number of real numbers in the array is given (n)
then in the next line the real numbers are given.
Output
Print the required answer, i.e., "found" or "not found".
Constraints
1 <= n <= 3*10^5
Sample
Input: 2 3 0.7 0.5 1.2 5 1.2 1.3 1.22 0.999 1.5 Output: found not found
hide comments
appy:
2014-01-11 18:19:52
getting wrong answer...we have to take double or float for the input...sum1 help plss
|
|
Saransh Sharma:
2014-01-11 15:42:17
piece of cake if you get it :P |
|
|RAMSDEN|:
2014-01-01 20:24:55
nice prob :-) |
|
anurag garg:
2014-01-01 18:44:33
easy if you find the logic... |
|
Bhavik:
2013-12-28 18:40:33
fantastic question:)) |
Added by: | Aditya Gourav |
Date: | 2013-10-06 |
Time limit: | 0.100s-1s |
Source limit: | 500000B |
Memory limit: | 1536MB |
Cluster: | Cube (Intel G860) |
Languages: | ADA95 C C++ 4.3.2 CPP |