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

CHGIFT1 - Editorial

Problem Link:PracticeContestAuthorRoman FurkoTesterBalajiganpathiEditorialistUtkarsh LathDifficulty:SimplePre-requisites:Dynamic ProgrammingProblem:Given a list of N integers, each between -9 and 9,...

View Article


prize structure

what are the prizes for codechef long contest?

View Article


NO rank for long challenge

Why am i getting NA in the place for long challenge rank???

View Article

NO rank for long challenge

Why am i getting NA in the place for long challenge rank???

View Article

Oops!! We didn't find any country code for you." in my rank and rating?

Why does it show "* Global Rank / Country Rank Oops!! We didn't find any country code for you." in my rank and rating?

View Article


Kernel Module Programming related problem

Hello , We are working on a project of real time system and we have a module in Kernel Space. That module has some functions and we have an Application that also has some functions with same name.This...

View Article

The Lead Game- Wrong Answer is coming again and again

include<stdio.h>include<stdlib.h>int main() { int i, x, y, n, max = 0, w, sumx=0, sumy=0 ; scanf("%d", &n);for (i = 0; i < n; i++) { scanf("%d%d", &x, &y); sumx += x; sumy +=...

View Article

REIGN - Editorial

PROBLEM LINK:link:ContestAuthor: @kostya_byTester: @white_kingDIFFICULTY:EasyPROBLEM:This can be solved using dynamic programming. Call best_forward[i] to be the maximum prosperity of a sequence that...

View Article


POKER wrong answer

I am trying to solve this problem and I get wrong answer here could someone give me a test case where my code fails . I tried input11AH KH QH TH JHKH 5S 3C 5C 7DQH QD 2S QC 2CAH AS AC 2C 5DAH AS AC AD...

View Article


inversion count

I am trying to solve this(http://www.spoj.com/problems/INVCNT/) question... I ma able to sort the array correctly using merge sort but am not able to get the correct inversion count...any help? my...

View Article

tutorial for learning c

sir, i want to learn c, so can you send me a link of tutorial of c/c++..? i will be thankful to you..

View Article

why wrong answer PRCODE?

my solution here gives wrong answer. can you give me a failing testcase.

View Article

Problem compiling SUMTRAN.. I am not using packages!!

Why am i getting compile error.. I am not using any package in my code!! please help this is the error Main.java:5: class Main1 is public, should be declared in a file named Main1.java public class...

View Article


Segment Trees With LAZY PROPAGATION

Can anyone explain segment tree with lazy propagation as I couldn't get it & how is it faster than segment tree as both are top down approaches ,so how is that lazy makes it faster

View Article

Recursion executing line after break statement

private String getPhrasedvalue(int current_value, int next_value, String str) throws SQLException { String[] words = str.split(" "); String current = words[current_value]; String next =...

View Article


TLE matchstick

Was trying to solve http://www.codechef.com/problems/MSTICK by Segment tree but still TLE pops up..:(. Heres my code .plz help me out..:( http://www.codechef.com/viewsolution/3448843

View Article

why is my approach wrong ?? knapsack problem

http://www.spoj.com/problems/PARTY/i know this approach is not correct but why ???//Data Structure includes #include<vector> #include<stack> #include<set> #include<map>...

View Article


Problem in the code for the question: Feb Cook-Off 2014 - Chef and Reunion

For the problem in the February Cook-Off 2014 - Chef and Reunion we need to calculate the number of inversion in an array so i tried to apply an algorithm using merge sort and calculating the number of...

View Article

HOW TO SUBMIT A SOURCE?

see title ^

View Article

can 0-1 knapsack be implemented using 1D array??

I found implementation using 2D array. But how to implement it using 1D array and if it is not possible then why???

View Article
Browsing all 39796 articles
Browse latest View live


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