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

i want a code to find prime numbers in a given range using while loop.

#include<stdio.h> #include<conio.h> void main() { int x,z,y=2; //x is lower limit and z is upper limit of range printf("enter the no."); scanf("%d%d",&x&z); while(x<=z) {...

View Article


Image may be NSFW.
Clik here to view.

QTREE6 - Editorial

PROBLEM LINK:PracticeContestAuthor:Minako KojimaTester:Gerald AgapovEditorialist:Jingbo ShangDIFFICULTY:HardPREREQUISITES:Link Cut Tree, Heavy-Light DecompositionPROBLEM:Given a 0/1 colored tree of N...

View Article


Cannot view current contest ranking

I want to tell that we cannot view the current contest rankings.After checking the first few pages we cannot look further..:( Please look into the matter

View Article

IARCS Problem

http://opc.iarcs.org.in/index.php/problems/TASKFORCE is the problem I've been working on for so many hours, yet no luck. Please Help!!#include <iostream> using namespace std; int edg(int); int...

View Article

Please like me problem error

//CODE DELETED, LIVE CONTEST//using long long int i am getting wrong answer please explain...

View Article


divquery problem

hallo, I just registrated and saw this interesting problem here http://www.codechef.com/problems/DIVQUERY/ ,I make some code I and I think it is fine ,when I type the same input like in the problem the...

View Article

paying up(wrong answer)

include<cstdio>include<cmath>int main() { int x,sum,flag=0; unsigned int t; scanf("%u",&t); int nonotes,money,d[20]; for(unsigned int k=1;k<=t;k++) { fflush(stdin);...

View Article

LEALCO - Editorial

PROBLEM LINK:PracticeContestAuthor:Vitaliy HerasymivTester:Anton LunyovEditorialist:Anton LunyovDIFFICULTY:EASYPREREQUISITES:Bitmasks, BacktrackingPROBLEM:You are given an array R[0], R[1], ..., R[N-1]...

View Article


Can Mtech students appear for ACM-ICPC WF ?

Are MTech or MS students eligible for ACM ICPC WF ?

View Article


WA in MARBLEGF

I am having a problem in solving this question - http://www.codechef.com/DEC13/problems/MARBLEGF/ here is my solution-http://www.codechef.com/viewsolution/3073979 If someone could help me to point out...

View Article

Statement for problem SEAGRP updated

Hello @all,As some people were saying that the statement for this problem had some minor notation issues, namely with the limits for the test cases and for the values of n and m, I've decided to speak...

View Article

C or Cpp which is better?

i have this doubt from when i started solving codechef problems.Now i am programming in C language only.Is learning complete C language is more adequate to become a good_programmer/master in codechef...

View Article

cant understand why it is showing wrong answer

include <iostream>include <iomanip>int main() { using namespace std;int wdraw; float bal; float left; cin >> wdraw; cin >> bal; if(wdraw <= bal) { if(wdraw%5==0){ left =...

View Article


Complexity and Execution time

Suppose a C++4.8.1 program is O(N) and N=10000, then how much time (in seconds) will it approximately take to run?

View Article

what is buffer

actually what is buffer why the values will be stored in buffer during programming

View Article


SEGMENTATION FAULT

When I am trying to get a string as input from scanf it is running well on my codeblock IDE, but here it is giving me an SIGSEGV error. Please help. My code is here...

View Article

look at this c program and check the answer and correct it...

include<stdio.h>void main() { int x,y; char ch; do{ printf("\n press '1' for addition"); printf("\n press '2' for substraction"); printf("\n press '0' for exit \n"); scanf("%c",&ch);...

View Article


Help with MTRICK

I have tried to optimize my code in almost every possible way yet i'm getting TLE. The link to problem is http://www.codechef.com/JAN14/problems/MTRICK and to my solution is...

View Article

Help me with MAXCOUNT test cases where my program does not work

What am I getting wrong answer for this program(MAXCOUNT)[from easy]? I have tried all possible test cases ie. for 1 occurence, for all occurence etc..Please help me find a test case where my code does...

View Article

Image may be NSFW.
Clik here to view.

BESTBATS - Top Batsmen explanation

NOTE: look for image numbers and corresponding images below. **codechef BESTBATS - "top batsmen" guidance: lets sort scores of players(qsort). here i sorted in decreasing order. the number of ways...

View Article
Browsing all 39796 articles
Browse latest View live


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