They say that repetition is the mother of skill, and I think they’re right.
The first time, you might be lucky. You might muddle through a problem on a hunch. If you succeeded – well, good for you. Just don’t think it means you can do the thing.
Repetition cements your muscle memory. Solving the problem again* more quickly suggests that you understand what’s going on. If you can do the thing consistently in different contexts, you can feel confident that you’re heading towards mastery.
Do the thing. Do it again. You’ll get better. You’ll get luckier.
*Or being able to re-fix it when it breaks