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

Codechef's T-Shirt

What I should do to get codechef's T-Shirt?

View Article


Correctness of algorithm?

Hi i have following problem You are given two array, first array contain integer which represent heights of persons and second array contain how many persons in front of him are standing who are...

View Article


Help on Fast input/output

can someone explain me what's fast input/output. I m sorta new to this stuff and would really appreciate some help. Thank you.

View Article

can't figure out why its wrong, pls help!

i tried to do this problem : http://www.codechef.com/problems/APGE02and the thing is in my system m getting its answer but on posting my code here on codechef, it says output does not match like...

View Article

What's happening on codechef ?

In today's lunchtime contest , the site got offline for 10-15 minute . I click on poster of november cook-off on home-page , then october challenge pops up . I tried to open the today's lunch question,...

View Article


holes in the text wrong answer

#include <stdio.h> #include <string.h> int main() { int hole=0; int i; char word[100]; scanf("%s",&word); fflush(stdin); i=strlen(word); for(i=0;i<=40;i++) { if(word[i]=='A' ||...

View Article

Image may be NSFW.
Clik here to view.

Printf statement getting skipped in Numbers

Hey, this is regarding the problem, NUMBERS which came in the Lunch Time competition. To check my code, I put a few printf statements in my code. But somehow, the printf statement for the strings,...

View Article

Improving efficiencey of Pairing Program.

I was going through some sample questions on the net. I found a question where you have to count the number of pairs that can be formed according to the info given below:Hobbes has challenged Calvin to...

View Article


Picking a Group of Tasks while Minimising Time

The ProblemWe are given N number of tasks of N days each. Each takes time t_i to performed. Our job is to find out which combination of tasks minimizes the total amount of time taken. The constraint is...

View Article


What is run time polymorphsim in c++?

Can any one please help me?

View Article

Sum of powers

can anyone please tell what will be the properties of a variable c in equation a^x+b^y=c ?????

View Article

Image may be NSFW.
Clik here to view.

Different Answers

I ran the code given below on Ideone and on Xcode (an IDE on mac). Shockingly, they gave me two different answers for the test cases given along with the problem.Ideone shows "Nana". Whereas Xcode...

View Article

Longest Weird Sequence

I was doing this question. http://www.codechef.com/problems/LWS Finding longest weird subsequence. My approach is to first find LIS and then LDS from the remaining string. I know that this approach is...

View Article


Knapsack problem

Hey I just learnt the knapsack algo and tried to solve http://www.codechef.com/problems/PPTEST/ but its showing WA. This is my code#include <iostream> using namespace std;int main() {int t;...

View Article

Range Update in BIT

Is it possible to update a range in Binary Indexed Tree...?? I want this to solve the http://www.codechef.com/problems/FLIPCOIN problem using Binary Indexed Tree(BIT).

View Article


MAXCOUNT- Editorial

PROBLEM LINKSPracticeContestDIFFICULTYEASYEXPLANATIONThis was supposed to be a problem that anyone who knows basic programming could solve and I'm glad that it's satisfied our expectations.For the...

View Article

Please explain me what are binary indexed trees and how do they work.

I am not able to understand how to implement binary indexed trees. I cant understand how they work. If someone could please explain me in detail how to use them along with an example.Thank you.

View Article


Set and Vecotr-Can anyone tell me which is faster?

When we enter the elements in the set it automatically gets sorted. But in a vector it takes another process to sort.Of course that depends on whether you want to sort it or not.But still i want to...

View Article

Determinant of a matrix

please can someone tell me how do i write a code for calculating determinant of a matrix in c.That works for all size of matrices eg. 33,44,7*7...and so on....

View Article

how should i start approaching codechef programming?

i have just started getting involved in codechef.. merely reading the practice questions i am not able to understand the way to approach the programmming. someone please help

View Article
Browsing all 40121 articles
Browse latest View live


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