It eventually worked for you - great. That doesn't prove that it will eventually work for everyone.
At some point, when something is not working, you have to write off the sunk cost. In many cases, there's no obvious threshold as to when you make that decision, and it's easy to think that maybe, if you'd just held out a little longer, been a bit more determined, you could have made it work. But you have to make a call, without knowing for certain either way. And it can be the right call, even if, with perfect information, you'd have made the other choice.
So, while I'm sure lots of the people saying "you should just have tried harder" are doing so with complete good will, it's not helpful. You don't know, for another random person on the internet:
* how much work they put in
* what other burdens they were carrying
* what other needs and responsibilities they could use that time and energy on
* how their mind is different to your mind
etc, etc. In short, you don't have most of the information needed to make that decision for them, and you don't have any call to judge them for it.