What kind of problems are easier to solve in Python?
Now, since Python is really gaining reputation among competitive programming also. What are some particular types of problem that are easier to code in Python compared to C++/JAVA?
View ArticleTRIQUERY - Editorial
Problem Link:PracticeContestDifficulty:MediumPre-requisites:line-sweep, rank-query DSProblem:Given N points (Xi, Yi), and Q queries (x, y, d), find for each query how many of the N points lie within or...
View ArticleHelp with segment trees - query processing
Hello all,I am now attempting to solve the problem FLIPCOIN in the practice section, medium difficulty level.I am aware that a naive solution gets TLE... However, I also know that some sort of segment...
View Article[SPOJ] LQDNUMS
Does anyone know how to solve this problem? http://www.spoj.com/problems/LQDNUMS/Or at least please give me the references for it. Thanks a lot in advance.
View ArticleHelp me understand this dp problem !
I am new to dynamic programming. I can't figure out how the solution given to this problem works, please explain how the answer given works. I'd also appreciate links to various resources to learn dp,...
View Articledon't get logic to dis spoj problem
www.spoj.com/problems/ADV04L/ here is d link of spoj problm I don't know how to solve it and how to deal with large FIBNACCI numbers Help PlzThank You
View Article1 problem 2 solutions
This is in reference to the problem FACTORIAL (Problem code FCTRL) link FactorialOne of solution got accepted:import java.io.*; import java.util.*; public class Main { public static void main(String []...
View ArticleNEXT PALINDROME
please tell me the test case for which i am getting a wrong answer.http://www.codechef.com/viewsolution/2298931
View ArticleDELISH - Editorial
Problem Link:PracticeContestDifficulty:SimplePre-requisites:Dynamic ProgrammingProblem:Given an array D[1...N], find max(abs((D[i] + ... + D[j]) - (D[k] + ... D[l])) : 1<= i <= j < k <= l...
View ArticleJune lunch time 2013 -ratings effect
The code chef team has said that we can participate in lunch contests but will it affect our short contest ratings or will it have a new rating system?
View Articletime complexity ..in int and long (java)..plz help
import java.io.BufferedReader; import java.io.BufferedWriter; import java.io.IOException; import java.io.InputStreamReader; import java.io.OutputStreamWriter; import java.io.PrintWriter; import...
View ArticleTime Limit Exceeds - TASTR
Hello, I am pretty new to code chef, and had tried my first program over here. I just tried out this question: http://www.codechef.com/problems/TASTRhmm.. as per the the explanation of the question,...
View ArticleDIFTRIP - Editorial
PROBLEM LINKSPracticeContestDIFFICULTYHARDPREREQUISITESTree Data Structure, Suffix ArrayPROBLEMThere is a tree of N nodes numbered 1 through N. Let deg(i) be the number of nodes connected to node i....
View ArticleWhat is the logic behind this type of code?
main() { int a,b,c; int count = 1; for (b=c=10;a="- FIGURE?, UMKC,XYZHello Folks,\ TFy!QJu ROo TNn(ROo)SLq SLq ULo+\ UHs UJq TNn*RPn/QPbEWS_JSWQAIJO^\ NBELPeHBFHT}TnALVlBLOFAkHFOuFETp\...
View ArticleNICEQUAD - Editorial
PROBLEM LINKSPracticeContestDIFFICULTYEASYEXPLANATIONTo detect whether the quadrangle has an integer area we will use the Pick theorem which states that the area of a grid polygon can be calculated in...
View ArticleIs strrev() function not available in standard gcc compiler
I'm using Dev-cpp running on Windows Platform which shows no error and works fine with the strrev() function but when i run my program here, it gives compile time error with the following message...
View ArticleTowers of Hanoi(Facebook Sample problem)
This is the Towers of Hanoi problem in which you've to find the minimum number of moves required to move from one configuration to another.(Not the classical.Thats easy).I've been stranded on this for...
View ArticleEditorials On Codechef
@admin Can any user write editorial for the problems used in long and short contest or only authorised users have rights to do that.... ??
View ArticleATTIC- WRONG ANSWER
what is wrong in dis code??#include<stdio.h> #include<string.h> const int MAX=1000001; int count(char[],int*); int main() { int t,days,c,i,k; char p[MAX]; scanf("%d",&t); while(t--) {...
View ArticleVolunteership for Codechef for School
Hey @everyone, I was surfing Codechef for schools and suddenly I came across this page http://www.codechef.com/school/volunteer which asked of becoming the Volunteer and after reading whole document a...
View Article