Greetings,
Just wondering - is extrude the only operation that leaves vertexes (or any extra mesh data) behind when cancelled?
There is at least one more: Y, cancel.
For instance if you want to move a selection in the Y-axis and instead of G, Y, you just press Y...
But it is not important to learn all the cases, where this can happen and try to avoid them, or so...just know how to solve them (M > Merge > By Distance). (It's a good idea, to check the Normals after that...)
You are also usually able to tell if something is wrong because when you go to Object Mode, there will most likely be a weird shading or pinching. Also in edit mode there are kinds of "codes" that lets you know you have something wrong with the mesh. Faces will get more transparent or opaque, they well change slightly if you have flipped normals, etc. Those are a bit hard to notice, but they are surely helpful and you do get used to noticing something might be wrong by those kind of subtle signs.
Thanks to all who have responded - you've provided a lot of great advice!