Блог пользователя MTX_AS

Автор MTX_AS, история, 3 года назад, По-английски

I've recently realized that I find case work problems quite hard, I often just miss out some cases and can't debug the the code. I would love to ask you whether you have some tips for case work problems.

Also, is there a list of case work problems, or could someone recommend some problems for this topic?

Полный текст и комментарии »

  • Проголосовать: нравится
  • +14
  • Проголосовать: не нравится

Автор MTX_AS, история, 3 года назад, По-английски

Problem: here

Submission link: here

Why I think it shouldn't exceed the limit:

Let's look at my query function (it does the queries):

function code

now the solve function:

solve() code

So, I don't get a runtime error due to the assertions. But it should work, because $$$t<=10^4$$$ times we do at most $$$2$$$ queries, and we do also some build queries, which are $$$\leq 4\cdot10^4$$$. $$$2\cdot 10^4 + 4\cdot 10^4 = 6\cdot 10^4$$$, which is the maximal number of queries possible. Have you got any ideas what's wrong here? Help would be really appreciated. Thank you.

Полный текст и комментарии »

  • Проголосовать: нравится
  • +2
  • Проголосовать: не нравится