...and at least I went to bed having solved one problem! Even if I was the one who created it in the first place...

You learn from mistakes (although in my case, very slowly) but it's better to learn from other peoples'. Plenty of learning opportunities from me, then