Quantcast
Channel: CodeChef Discuss - latest questions
Browsing all 39796 articles
Browse latest View live
↧

MAXCOUNT: Why Runtime Error SIGSEGV?

[My Code][1] http://www.codechef.com/viewsolution/3971016Please Help!

View Article


Compilation Error: itoa

why does the compiler doesn't recognize itoa string function. I have included <string> and <stdlib> header file.here is the exact error code : prog.cpp: In function �int main()�:...

View Article


Given a BST, find all sequences of nodes, that will generates the same bst.

Given a Binary Search Tree, generate all the sequences which would create the same binary search tree. For eg: if bst is 5 / \ 3 7 then output: 5 3 7 5 7 3If bst is: 5 / \ 4 7 / / \ 1 6 10 then output:...

View Article

Koicost Spoj

http://www.spoj.com/problems/KOICOST/ I'am not able to understand the problem correctly. It says "While there is a path between vertex u and v, delete the edge with the smallest weight. Cost(u,v) is...

View Article

PYTHON TLE JAVA AC!!

I am getting a TLE in my python code whereas a code with the same complexity of O(n^2) in java, I am getting AC!! My solution link for python is:http://www.codechef.com/viewsolution/3971729 My java...

View Article


New Sorting Algorithm

I study in class 12, India. I have developed a new sorting algorithm. I dont have much knowledge about the names of sorting technique, ignore if you know this technique.Let the array is a[].int...

View Article

algorithm of pouring water.

http://www.codechef.com/problems/POUR1this is a question i found while solving problems from pratice arena on codechef. I saw many solutions but could not understand the logic. On some of the posts i...

View Article

I ask again !!!

Its been over 7 days since i have asked a question of spoj on the codechef forum http://www.spoj.com/problems/SCUBADIV/I ask again please explain me the approach of this problem

View Article


COMPILER-Getting WA

Can Somebody give test case for which my solution is wrong Soln-http://www.codechef.com/viewsolution/3972414

View Article


ANUUND-time limit exceeded

I am using insertion sort for this problem.Won't it work?

View Article

ORDERS SPOJ

How to solve this problem http://www.spoj.com/problems/ORDERS/ I have seen some solution implementing tree to solve it but not able to understand it please help me out....

View Article

RUN TIME DIFFERENCE between using Integer and int in JAVA

In JAVA is there any difference in using Integer and int at run time ?? 1.Integer n[] = new Integer[100000]; 2.int n[]= new int[1000000]; on solving this question i got AC when i used Integer,but got...

View Article

WA in LEBALONS

I am solving this question, Here is my solution.I am getting WA.I read the editorial from this page, but I am unable to understand any thing.I will be very thankful if any one can help me finding...

View Article


sumtrian : lot of test cases tried but still wa

# include <iostream> # include <stdio.h> # include <math.h> # include <list> # include <algorithm> using namespace std; int arr[100][100], val_arr[100][100]={0}; int value...

View Article

why do i get wrong answers .. i use c++(gcc-4.3.2)

include <iostream>using namespace std; int main() { int x; float y,z; cin>>x>>y; if (x%5 != 0){ cout<<y; }="" else="" if="" (x=""> y) { cout << y;} else { y=y-(x+0.50);...

View Article


INTEG @user-rsaha solution to this problem

I could not understand the 3rd step .. :(..Can somebody please explain??http://discuss.codechef.com/questions/23733/integ-editorial

View Article

TABUS algorithm

Hello,I have made the TABUS problem,tested it with different test cases,and they all succeeded,but I still get a wrong answer.Apparently,this line of code makes the difference &&...

View Article


Binary Search

Do you want to know about Binary Search? Do you want a right place to learn it? Open the link given below and get a right place :) My second blog post:...

View Article

need guidance in sums in triangle problem

hi i have been working on sums in triangle problem http://www.codechef.com/problems/SUMTRIAN i don't want to see the solutions i just want to know the basic approach behind it so that i can solve it...

View Article

WA in SUMTRAIN

I have tried the SUMTRAIN problem, as suggested in the comments below the problem, i have to add the largest integer per row irrespective or their position . so tried this :...

View Article
Browsing all 39796 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>