When there is a problem that I don't know the approach to or if I have coded the solution but it doesn't work for some reason, I usually check the editorial or view others solution. But if I upsolve the problem right away, it feels like cheating because I already know the solution.
So I wait about 2~3 days and try to upsolve. However I feel like I still remember the solution from few days ago and I am not confident that I will be able to solve this problem later on if it appears. How much should you wait after viewing the solution to a problem before trying to upsolve?