hiddentesla's blog

By hiddentesla, history, 7 years ago, In English

Hello, currently i struggle with output only task. I usually can only come up with the most brute force solution. Is there any tips to deal with these kinds of problem?

  • Vote: I like it
  • -1
  • Vote: I do not like it

»
7 years ago, # |
  Vote: I like it -13 Vote: I do not like it

You can try to analyze the given inputs separately and test for special cases of the problem. For example, this problem basically asks you to color a graph, which in general would not be possible in P, but once you look at the test data you can see that most of the cases contain special graphs which are easier to solve.