Just an idea on faster publication of editorials
Just saying...if the authors of the problems on long/short contests submit an explanation along with the problems there wouldn't be any delays. It'd be great if their explanation included the following...
View Articlepython run time error (NZEC) in spoj
My following code returns me the run time error in spoj during submission. Can anybody tell me how to remove this error. here is the link of the question http://www.spoj.com/problems/SERVS/import numpy...
View ArticleSmall tree problem
In a weighted tree, how to find for every node the other node farthest from it (in linear time)?Thanks
View ArticleADVICE NEEDED
hiii, i am happy to say that i have solved almost 50 questions and still willing to practice more...my problems is that most of the quetions i solved is from easy section and it needs only knowledge of...
View ArticleWA on firesc
I'm trying to solve http://www.codechef.com/problems/FIRESC/ problem. Im using bfs instead of dfs unlike the editorial.This is my solution http://www.codechef.com/viewsolution/3235157.Can somebody help...
View Articlepaying up wrong answer
#include<iostream> #include<math.h> using namespace std; int main(){ int ans,size,test; cin>>test; for(int i=0;i<test;i++) { cin>>size; cin>>ans; int a[size]; for(int...
View ArticleLUCKY3 - Editorial
PROBLEM LINKSPracticeContestDIFFICULTYMEDIUMEXPLANATIONFirst of all, notice that there are exactly 1022 lucky number of length between 1 and 9. We can solve problem for each lucky number independently,...
View ArticleTERBO SORT
#include<stdio.h> int main(){ long int i,j,t,arr[1000000]; int k; scanf("%ld",&t); for(i=0;i<t;i++) scanf("%ld",&arr[i]); for(i=0;i<(t-1);i++) { k=0; for(j=0;j<(t-1-i);j++) {...
View Articleruntime errror in python
print("Enter two Numbers\n") a = int(raw_input('A=')) b = int(raw_input('B=')) c=a+b print ('C= %s' %c) this code is giving runtime error in python ..i tried it like 100 times on ideone.com
View ArticleRESQ - Editorial
PROBLEM LINKS:PracticeContestDIFFICULTY:SimplePREREQUISITES:Math, Prime FactorizationPROBLEM:The aim is to find two numbers x and y such that x * y = N and |y – x| is as small as...
View ArticleWhy are my getting the wrong answer?
I don't know why I'm getting a wrong answer for "The Morning Commute". It works on all of the examples they provided. Please help me!The Problem: http://www.codechef.com/problems/COMMUTEMy Code:...
View ArticleWA on FIRESC
I'm trying to solve http://www.codechef.com/problems/FIRESC/ problem. Im using bfs as opposed to dfs unlike the editorial. Can someone please help me find where im going wrong? This is my solution...
View ArticleCheating in December Long-DECORATE
These 2 submissions seem to be identical.@admin do have a look at it. PS:Both are in the top 20 .http://www.codechef.com/viewsolution/3095229http://www.codechef.com/viewsolution/3068078
View ArticleConfusion regarding time limit
One of my code on ideone gives 0.11 seconds. (Java code using biginteger class), but here on codechef gives TLe. I m bit confused regarding this, please can someone sort this.
View ArticleCROWD - Getting Wrong Answer
The Problem is Three is Crowd. Link is http://www.codechef.com/problems/CROWD My code is include <iostream>include <iomanip>define ll unsigned long longdefine mod 1000000007using namespace...
View ArticleAnagram--Can you tel me what is the problem in my code?When i submit it shows...
My solution is herehttp://www.codechef.com/viewsolution/3243203
View ArticleGenerating Test Cases
I want to set a problem(its my first time), but I have no idea to generate test cases and what a Test Generation Plan is? I would like to learn it in detail ( While answering, please remember that its...
View ArticleFastest way to check the number of nodes reachable from source node
I was doing a problem which involved finding number of reachable nodes from a source node. I implemented this via dfs. I was wondering whether this was the fastest way to check or whether there was any...
View ArticleUsing online compiler .
I generally use online compiler Ideone.com and i am always very careful to make the codes private.Yesterday i was doing the same, made the codes private and then compiled the codes but today i found...
View ArticleAwesome JAN14!
Hello @all,I have to say that I absolutely loved JAN14 and even though I haven't had that much time as I would have liked to attend it (due to exams and similar constraints), I managed to solve three...
View Article