We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
- Prepare
- Mathematics
- Geometry
- Circle City
- Discussions
Circle City
Circle City
Sort by
recency
|
64 Discussions
|
Please Login in order to post a comment
Passed all but one test case:
some tese case fail this code .....can you tell why that.....??
int solve(long int d,long int k) { int r=sqrt(d); int t,p,ans=4; //char *possible,*impossible;
}
//THis code clear all test cases
static String solve(int d, int k)
can anyone help me out... i get TLE on testcase 2. Is my code efficient?
Could be solved easily with https://en.wikipedia.org/wiki/Fermat%27s_theorem_on_sums_of_two_squares and where = number of decompositions of in two squares. The French version of the above page gives this formula and the meaning of and .