TRANSFIG - Editorial
Problem Link:PracticeContestDifficulty:MediumPre-requisites:TreesProblem:You are given the preorder and the postorder traversals of a rooted K-ary tree. Find how many such trees are there having the...
View ArticleINVITES - Editorial
Problem Link:PracticeContestDifficulty:MediumPre-requisites:Dynamic Programming, TreeProblem:Given N families, each of whom declares exactly one enemy among the remaining families, find how many ways...
View ArticleALETHIO problem query
#include <cstdio> #include <cctype> #include <cstring> #include <cstdlib> using namespace std; int main() { char s[1001]; scanf("%s", s); int length = strlen(s); int maxnum = 0;...
View ArticleLunch Time June 2013
Is this some new contest by codechef? Whats the contest format? Link : http://www.codechef.com/LTIME01
View ArticleALETHIO - Editorial
Problem Link:PracticeContestDifficulty:EasyPre-requisites:ad-hocProblem:You are given a string of digits 0-9, and uppercase letters 'A'-'Z'. Given that you are allowed to modify atmost one letter to...
View Articleattic problem cook off june .
can someone please tell me why my code was giving WA ?#include<stdio.h> #include<string.h> int main() { int times,i,k,sum=0; scanf("%d",×); for( i=0;i<times;i++) { char...
View ArticleTYTACTIC - Editorial
Problem Link:PracticeContestDifficulty:SimplePre-requisites:dfs, range sum queriesProblem:You are given a rooted tree T, associate with each vertex v a weight skill[v]. Also given are a set of queries...
View ArticleCHEFGAME-WA
I was getting WA for CHEFGAME after implementing Prim as in the editorial.Could somebody tell where am I going wrong?Code
View ArticleSubmission of a solution after an event ends
Please tell me where can I submit the questions asked in long event or cook-off after the event has ended.
View ArticleWA ALETHIO
inCase = raw_input() maxInt = 0 current = "" cInt = ['1','2','3','4','5','6','7','8','9','0'] LetterUse = False index = 0 for element in inCase: if(element in cInt): ## is a number current+=element...
View ArticleJune Lunch Time 2013
Can anybody tell me what is June Lunch Time 2013 ? I mean what is Contest Duration and number of Questions. Is it like Long Contest or Short or something in middle ?
View ArticleJune cook off 2013 Attic Crossing Problem
here is my code ..!import java.io.*;class Attic { public static void main(String args[])throws IOException { BufferedReader br=new BufferedReader(new InputStreamReader(System.in));int t,arr,days,max;...
View ArticleATTIC problem
Can u tell me whats wrong with the code below , the code is accepted but giving an execution time of 2.53 sec ! How can i optimize it ? Provide some tips !int main(){ int t ; cin>>t; getchar();...
View Articlecome on somebody pls answer this question.Is it necessary that a file created...
pls give appropriate explanation supporting your yes/no
View ArticleSolve COPS AND PRISONERS
http://www.codechef.com/problems/APGE01I am getting WA in this question. please provide a correct solution. My solutions : http://www.codechef.com/status/APGE01,himanshujaju
View Articlesame program in java submitted but in c not
i have applied same logic to attic question of june cook of it was submitted in java but when i do it in c it is not submitted...it says wrong answer. why???
View Articlewhy tle show up?
#include<stdio.h> #include<string.h> int main() { long long int t; char s[500001]; long long int i=0,length=0,jump=0,day=0; scanf("%Ld",&t); while(t--) { scanf("%s",&s);...
View Articlegetting paragraph without using gets() function
This is my code...This will executing infinte times...can any help me to getting the paragraph without gets()char str[100];int i=0; for(cin>>str[i];str[i]!='\n';) {++i; cin>>str[i]; }If i...
View ArticleNeed explanation of a code..
Here is the problem linkSomebody plzz explain the solution of this problem given in the link below. I know this is not my solution, but i want to learn bit manipulation. Tried many self satisfying ways...
View ArticleFinding lowest common ancestor in Binary Tree
This is not like other Codechef questions but still very interesting. How do we find lowest common ancestor in Binary Tree in O(n) time provided that you do not have any extra memory to store parent...
View Article