This is a very good question. To be honest, through life you will always have those ‘moments’ where you get stuck and cannot see a way out no matter how hard you try. The best way to tackle it, from personal experience, is to take a step back and try to see the problem or issue from a different perspective.
I could go on as to how perseverance is the key to success etc, but in reality, it’s not on how hard you try, but rather how flexible you are as a person to find the solution to the problem at hand. The nice bit about science, is that there is no ‘right’ or ‘wrong’ as we are exploring!