I practice olympiad problems from books like Putnam and Beyond. Often I come across a problem that I simply can’t solve. After $\sim30$ minutes of deep thinking it feels like I’m ramming my head into a brick wall, since I’ve exhausted all avenues of thought I am aware of. What should I do in these situations? Move on to another problem? Give up and see the answer? Or spend more time on it?
My opinion is that you should sleep on it.
Move onto another problem, or just take a break, and come back to it later.
Also, if you’ve hit a brick wall you may just need to approach from another angle to find the way through.