The effects of cin.sync() are implementation-defined, it is not guaranteed to do anything (it's only a step above the infamous fflush(stdin), which is UB). The call to ignore(), as shown by Duoas is what you need if your goal is to consume all entered, but not processed, input characters.
Who cares, seriously? The only reason anyone is going to need to pause the console to read text is if they're just doing homework or learning. So why not just use system( "pause" ) in that case? Now if you were writing a more advanced program where cross platform capabilities and efficiency are important then you shouldn't use this but, let's face it, no one writing a program like that is going to be asking this question. :D
yeah, its true. i only want to use it for my school tasks but i just was interested in what ways you can do it the best. even if its just some homework i still like doing it the better way(s)...
i'm still a beginner programmer but im learning pretty fast and programming in school bores me cause its sooo slooooow going
The difference, then, is in the merits of doing it one way or another. Since the system() method is a positive security hole, among other things, it is better just to learn it the right way.
Some people like doing things the right way that's all. We could all call you codingshirk too. You'd still know what we mean and this is just a forum so "who cares"? It would still be wrong though...
For instance, it is wrong to put a space in my username. The space is there to satisfy the 3-char username minimum limit. You could call me L B, but it's still wrong, even though it looks right.
Things aren't always what they look like. system("pause") looks right, but it's wrong ;)
Maybe you just see no evil? I think cnoeval agrees.