SIGSEGV error in Team Split -plz help
i think this error is due to this statement.... int s[3000000]; plz help how to allocate this size array...
View Articleprime palindrome wrong answer
my code is giving wrong answer for the question http://www.codechef.com/problems/PRPALIN my code is: http://www.codechef.com/viewsolution/3636679someone plzz help me out....what is wrong with my code?
View ArticleSIGSEGV in COOK42 - ABCSTR
I've employed the same method described in the editorial just the implementation is a bit different. For each index calculate the no. of A's, B's, and C's till that index. Then calculate A[i]-B[i],...
View ArticleDIVIDING - Editorial
PROBLEM LINK:PracticeContestAuthor:Konstantin SokolTester:Gerald AgapovEditorialist:Tasnim Imran SunnyDIFFICULTY:CakewalkPREREQUISITES:Simple MathPROBLEM:Given a list of N integers check if their sum...
View Articlefread working principle
while ( (c=fread(buffer, 1, SIZE, stdin)) > 0) //buffer is a char array { for (j=0;j<c;j++) { if(buffer[j]==EOF) printf("\nokk"); if (buffer[j] == ' ') { if (ti % k == 0) d++; ti = 0; } else { ti...
View ArticleSSTORY - Editorial
PROBLEM LINK:PracticeContestAuthor:Bruno OliveiraTester:Mahbubul HasanEditorialist:Jingbo ShangDIFFICULTY:MediumPREREQUISITES:Suffix Array, Suffix Automaton, Binary Search, HashPROBLEM:Find the longest...
View ArticleMINXOR - Editorial
PROBLEM LINK:PracticeContestAuthor:Konstantin SokolTester:Gerald AgapovEditorialist:Tasnim Imran SunnyDIFFICULTY:MediumPREREQUISITES:Sqrt decomosition, TriePROBLEM:Given an array A of N integers, you...
View ArticleABCSTR - Editorial
PROBLEM LINK:PracticeContestAuthor:Konstantin SokolTester:Gerald AgapovEditorialist:Tasnim Imran SunnyDIFFICULTY:SimplePREREQUISITES:Ad-Hoc, MapPROBLEM:Given a string S which is consisted of characters...
View ArticleSubmitted code within 2 minutes.
I wonder seeing this ranklist of Feb Cook-Off 2014. All it wonders is how can someone code for a problem within 2-3 minutes of start of the contest. It takes at least 2 minutes in reading the question...
View ArticlePALIN3 - Editorial
PROBLEM LINK:PracticeContestAuthor:Konstantin SokolTester:Gerald AgapovEditorialist:Tasnim Imran SunnyDIFFICULTY:MediumPREREQUISITES:Manacher’s AlgorithmPROBLEM:Given a string S which is consisted of...
View Articlehow to improve my rank when there is no contest ??
how to improve my rank when there is no contest ?? sometimes i miss the contests and can't participate in each events so is there any way by which i can still increase my codeshef rank ???
View ArticleWrong answer in MAXCOUNT problem. Please help!!
I have gone through many test cases,yet I think I might be missing some special case or am making some silly mistake. Can anyone please help me out with the wrong answer..?? Here is my code in...
View ArticleExtension for making sure you make private submissions on Ideone
For all those users, who use Ideone for compiling and testing their codes onlineGentle reminder, Ideone has 3 privacy settings:Public: Codes are available to everyone, even shown publicly in recent...
View Articleviews on codechef cook off
yesterday i went through the March cook-off. which had 5 question.i felt the questions is not maintained as it should be.if we look towards the long contest the question toughness level increasing is...
View ArticleC code for the ATM question does not work :(
include<stdio.h>int main() { float Y; int X; //printf("Enter the available amount : "); scanf("%f",&Y); //printf("Enter the amount to be withdrawal : "); scanf("%d",&X);...
View Articlewhy this java code is showing a runtime error.
import java.util.Scanner; public class ATM{ public static void main(String[] args){ Scanner ip = new Scanner(System.in); double bal = ip.nextDouble(); int amt = ip.nextInt();...
View ArticleGENARSEQ - Editorial
PROBLEM LINKSPracticeContestDIFFICULTYEASYEXPLANATIONFinding x[k] at each step directly by definition is very slow. Let's do the following. After we find some x[k] let's mark all numbers greater than...
View Articlewa in abcstr
This code gave me wrong answer...Can someone point out the error?? http://www.codechef.com/viewsolution/3636945
View Article