ATM problem please tell whats wrong..
x,y=input().split() y=float(y) if(x>0andx<=2000)and(y>0andy<=2000)and(float(x)+0.5<=y)and(x%5==0): y=y-x-0.5 print("%.2f"%y) else: print("%.2f"%y)
View Articlei am not getting this unexpected output..can u explain it??
#include<stdio.h> #define FUN(arg) do\{\ if(arg)\ printf("CODECHEF...", "\n");\ }while(--i)\ int main() { int i=2; FUN(i<3); return 0; } output-CODECHEF...CODECHEF...
View ArticleHappy Birth Day Code Chef !!!!!
A very heart full congratulations to all the Code Chef organizers , participants on the 4rth Birth Day of Code Chef . I am a new user , registered i guess in September 2012 , and started participation...
View ArticleHow to increase ?
Hello everyone,Can anyone tell me that how can I increase my reputation so that I can vote for questions & comments .
View ArticleHow to prepare for GATE??
Hi friends, I am a B.Tech student. My ultimate passion is teaching.According to me teaching is most scared profession. I always love to share my knowledge, whatever I know. In order to become a...
View ArticleArt Of Reading Code
Hello everyone,I often find it hard to read other's code than to write mine own version of code but competitive programming is not just all about writing codes. I have often heard people that you learn...
View ArticleWhy no Summer Internship Contests ?
@admin and users : Don't you guys think that there should be hiring contests or something like that on Codechef, kind of like what they had on Hacker Earth this month. I mean we do have excellent...
View ArticleSPOJ RRANGE
I am trying to solve this problem RRANGE but cannot get an efficient approach with segment trees. I know I have to build the segment tree for the difference sequence but am unable to frame the complete...
View Articlefactorial question
count=0 t=input() def z(x): answer=0 while(x>5): x=x/5 answer=answer+x return answer while(count<t): print z(input()) count+=1 .......... ......... ........ this is my code.....it gives me the...
View ArticleMSTICK - Editorial
PROBLEM LINKSPracticeContestDIFFICULTYSIMPLEPREREQUISITESRange Minimum Query, Simple MathPROBLEMYou are given N matchsticks arranged in a straight line, with their rearends touching each other. You are...
View ArticleWhere are some editorials?
I don't understand why the editorials for some problems (probably harder) are missing? first exxample from april challenge - http://www.codechef.com/APRIL13/problems/STRQUERY - and for this month I'm...
View ArticleIs there any better solution to find the shortest path
I have an array in which in each row , all the vertices are connected. eg: 0 3 4 6 2 0 1 2 5 here there is a direct path in between each of the two nodes in each row if we take row1: 0 is connected...
View ArticleNZEC Error: Python
def main():n = int(raw_input()) initList = [] tempMax = 0 for i in range (0,n): initList.append(raw_input()) initList.sort() i = 0 for i in range (0,n-1): l0 = len(initList[i]) l1 = len(initList[i+1])...
View Articlepython runtime NZEC error
I looked at all previous post here in the forum, but I still can't figure out why I'm getting this NZEC here. I'm trying to solve SALARY, http://www.codechef.com/problems/SALARY and here are my...
View ArticleLUCKY10 Getting Worng Answer.
I got all the test cases mentioned in the question and cases given as counter cases in the forum also correct.And i tried many test cases of mine.And seems like correct to me.but still getting wrong...
View ArticleImplementation of Heavy-Light Decomposition
People who can please write Implementation of Heavy-Light Decomposition(with comments if you can). Couldn't find any good implementation.Thanks!!!
View ArticleBESTBATS:Getting wrong ans
sumone can please tell what is the mistake in following code...i am getting wrong answer http://www.codechef.com/viewsolution/2187870
View ArticleSorting in alogorithm::sort
which sorting method is used in algorith::sort?? pleasse explain cause i am getting tle in quicksort and ac with this inbuilt sort.
View Article