flatline's blog

By flatline, history, 9 years ago, In English

I have been practicing on TopCoder for some time and have been getting the warning about my code having more than "30% unused code".

I wanted to know a few things:

  1. Will I be penalized if I submit my code with more than the said amount of unused code? If yes what will be the penalty?

  2. In my case I was getting the warning because my template is a little long (35 lines in this case). But what exactly is wrong with having that big a template? Will I be penalized if I exceeded the Unused Code Limit because of my template?

I went through the TopCoder forums but couldn't get a definite answer to these questions, hence posting here.

Thanks in advance.

  • Vote: I like it
  • +8
  • Vote: I do not like it

»
9 years ago, # |
  Vote: I like it +3 Vote: I do not like it

Here it is in the rules.

Generally, the Unused Code Rule tries to penalize too much irrelevant text in your solution, so that in the challenge phase of a contest, it is easier for the readers to see what the actual solution is.

When you solve problems in Practice Rooms, however, there is no challenge phase, and the Unused Code Rule won't be used to decrease your points.