"I want to ask a question" - Ask them all here!

can i submit my logic to june contest and ask where it wrong?

@ani_1107

No it is not allowed as it is an ongoing contest.

Discussing of problems of a live contests are against the rules. So, Nope :frowning:

This seems more like a feedback. Minor glitches during contest arent uncommon. Nevertheless, its upgraded to a question to allow anyone else with similar issue vent out his grievance there (which will strengthen your point).

Hi!
I tried to submit a code but codechef isnt accepting it. It doesnt move forward to the window where it shows ‘running’, it always hangs on a specific code. When i tried to submit another code which is not related to the question, it accepted and showed a WA. But when i submit this specific code, it doesnt accept. What do i do?
I think its a bug or something

Please provide the exact link to the question.

Why do I am not able to view others solution of the contest Snackdown elimination round?
Also the editorial is taking a whole lot of time to upload.

Its best if you move this to the question related to snackdown editorial.

Probably because when they made the mirror, everyone was able to see the solutions and some people used it for cheating, so they denied access and forgot to revoke that. And true :frowning: editorials are taking long. There is a post regarding that issue already here: https://discuss.codechef.com/questions/100670/pleases-upload-snackdown-elimination-round-editorials

1 Like

If you have a specific problem you want solution of, you can request the fellow members of discuss to help you.

Why do I get SIGSEGV runtime error for this code?here is my code https://www.codechef.com/viewsolution/14165238
check it once

Firstly, dont spam discuss by asking same thing multiple times. Then, N varies from 1-10^9. For 10^9, you will exhaust the maximum recursion depth and hence get a SIGSEV. Your function has a limit upto which it can undergo recursion.

sorry for asking multiple times.what changes i have to do in my code?can u please tell me?

The changes are simple. First thing is, that the function repeats after every 6th number. Meaning-

F(1)=F(7), F(2)=F(8) and so on...

All you have to do is to compute the first 6 values of function (do some maths on paper!). Then, do N%6 and arr[N%6-1] is the answer. (To understand this, i repeat, DO it on paper, find out values of F(1), F(2)…F(8) in terms of A and B, and then it will make perfect sense!)

Thanks @vijju.:slight_smile:

In case you get stuck on implementation, you can view my code here-

https://www.codechef.com/viewsolution/13783648

Hi Team,

I tried to submit a solution to one of the problems on this site. However it shows as NZEC error. I have tested my code successfully with few test cases in my local IDE as well as on ideone.com

Since, it is failing at codechef, I understand my code is failing with few test cases. Now, how to understand -

  1. What is the actual runtime error the code is throwing?

  2. For which test case (set of inputs) my code is failing?

Regards,

Lalitha

Please give a link to the question, as well as your solution. Because without seeing your code, its not possible to pin-point the exact reason behind the error.

Hi,

Thanks for the reply. I would want to rectify the error myself at least till I give up… :slight_smile:

I am more keen in understanding, where in this website can I find the output the code is generating? I am just seeing a NZEC in the MySubmissions page; but not clear of what exception the code is throwing.

Regards,
Lalitha

NZEC error most commonly happens when you access an array out of bounds, especially in JAVA. I will suggest you go through any nested loop and make sure its of type-

for(i=0;i<n-1;i++)
   for(j=i+1;j<n;j++)