Rabbit_White's blog

By Rabbit_White, history, 9 days ago, In English

First, let me describe how I usually approach problems. My approach has two parts. First, I work through the samples by hand to get a feel for the problem. For example, I might try to figure out whether a greedy strategy works in a game or which cases I need to consider.

Then I think about whether any familiar algorithms or data structures might help. For example, if a problem involves updates and range queries, I think about segment trees or Mo’s algorithm. I also try some tricks I’ve learned. For instance, when matching many pattern strings against many text strings, if the Aho–Corasick algorithm is hard to apply, I might try grouping the strings by length. If their total length is $$$n$$$, there are only $$$\Theta (\sqrt n)$$$ distinct lengths.

But as ad hoc, constructive, greedy, and game problems become more common, I’m starting to wonder whether my approach works well for ad hoc problems. These problems often hinge on one key observation that completely changes how you look at them. Working through the samples helps, but often it isn’t enough. Sometimes I have to try many more cases, even playing around with a test case that has over 100 numbers, before I spot a pattern. I can try to guess what’s going on, but that’s hard too.

I asked one of my teammates, who’s always good at ad hoc problems, how he approaches them. He just said, “Pay attention.”

So, does anyone have any advice on how to approach these problems or get better at spotting the key observation? It would really help me.

Full text and comments »

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

By Rabbit_White, history, 2 weeks ago, In English

In my view, coding and debugging proficiency is every bit as crucial as analytical thinking.

During my summer 2026 training, I often fell short of full marks simply because I ran out of time. I did not regard it as a serious issue—until something happened that really hit me.

On October 30, I failed to solve "Migrate" due to weak debugging skills. I spent so long debugging that I forgot to secure some subtask points, ending with 100+100+0+0.

In daily training, nearly every contest contains one or two problems that I know how to solve but fail to execute.

Therefore, strengthening my coding and debugging ability—what we call "mali" in Chinese, roughly meaning coding proficiency—is essential for me, as NOIP is approching.

Thank you for your advice.

Full text and comments »

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