When you call query_post it replaces the main query object with one of its own, but that isn't desirable. If you want to return to the main query, you have to call wp_reset_query to do so whichr estores the original query.
I'd advise strongly against the use of query_posts and instead suggest you use WP_Query. Query_posts is wasteful, slow, encourages bad practices, does not nest, and can get incredibly confusing.
I recommend you read this:
Its a presentation by a core developer, once you've read that you should know everything you will ever need to know, it contains all the important things that normally takes people years to learn, about how to do querys, what kinds and when to use them, and how to modify them