rte in my code for delish
can anyone suggest changes in my code it is giving run time error,i beleive the the logic is correct but it gives sigsegv.problem: http://www.codechef.com/problems/DELISHmy code:...
View Articlefinding subsets in an array
Pls suggest an algorithm to find the maximum no. of subset of length k in an array of length m where k<=m , having sum equal to a constant factor...e.g an array of length 112 5 1 2 4 1 6 5 2 2 1k=6,...
View ArticleSorting large array of long long int
Hey guys, i'm working on a problem where I have to sort large array of long long int ( array size of nearly 1000000). I've tried to do it with merge sort as it has a complexity of O(n*log(n)) in worst...
View Articlesigsegv in delish
can anyone suggest changes in my code it is giving run time error,i beleive the the logic is correct but it gives sigsegv.problem: http://www.codechef.com/problems/DELISHmy code:...
View ArticleWant Some Test Cases for Little Chef And Numbers?
I tried Some of my own test cases,code working fine..but getting WA after submitting.. Can any one provide some test cases to check where Iam actually getting WA
View Articledoubt chef and cake
i have tried for many test cases my output is correct but it is showing waalso do the test cases include this type of input :20 20 1 130 30 11 11my code:...
View Articlesorting array of struct
hey why code is not able to sort on the basis of "e" when the inputs are : 100 4,4 5,200 6,2 5//JUST PRACTISING #include<cstdio> #include<iostream> #include<list>...
View Articlebest way to sort an array
pleas can anyone tell me best way to sort an array.....also explain its algorithm and its working. best way means least complexity.
View ArticleTest Cases Still Weak for SSTORY even after Re-judge
One of my solutions was still Accepted though it should give wrong answer. My code gave 'c' for s1="aecd" and s2="acad", where the answer should be 'a'.
View Articlecan someone please explain the solution to this problem?
Can someone please explain to me what the logic behind the solution to this problem is:"A Simple Equation" - http://www.codechef.com/problems/EQUATIONI looked at a few solutions that produced the...
View Articleproblem with contest configuration
hello,am getting problem with contest configuration error whenever i try to submit a solution.Are others also getting the same error?and what is this error?
View ArticleBEX - Editorial
PROBLEM LINKSPracticeContestDIFFICULTYEASYPREREQUISITESStack Data StructurePROBLEMHarry has a lot of books messed on the floor. He keeps a pile of books. At any time, he can put a book that has some...
View ArticleThree way communication giving wrong output on codechef
# include <stdio.h> # include <math.h> inline int scan() { char c = getchar_unlocked(); while(c < '0' && c > '9') c = getchar_unlocked(); int n = 0; while(c >= '0'...
View Articlewhat is o/p and explain why like that for below c program
{ float x=1.1; while(x==1.1) { printf("%f\n",x); x=x-0.1; } return 0; }
View ArticleSuggestion: Custom testing for codechef
Just like we have custom testing for codeforces, why can't we have something similar for codechef also?This will solve the problem of ideone leaked solutions and will also be very helpful. :DJust my...
View ArticleExtending MARCH14
Regrading of SSTORY that happened yesterday suprised me. I didn't have enough time available so I decided to do first six problems last week, and some more tonight. It all started out great, but now,...
View Articlehow to know when to apply Binary indexed Tree??
Had been studying BIT past few days and have got the idea how does it work but unable to figure when it is used like how to know it is being used in http://www.spoj.com/problems/CTRICK/ and...
View ArticleInteresting observation
I just noted that the top 2 guys in Indian ranking have the exact same long contest rating points, ranking and rating graphs. Coincidence...
View ArticleMIKE 3 output
mine is able to give 12 for this test case ( http://discuss.codechef.com/questions/39472/just-reevaluate-mike3 ) but still WA... I am new on codechef plz tell what is output format for this problem?...
View ArticleSIGFPE in March long Maximum number, GCD condition
I'm getting a runtime error in the probhttp://www.codechef.com/MARCH14/problems/ANUGCD/I've checked for array index boundsand the constraints clearly say that input can not be zer tooany suggestions?
View Article