I am totally new to c++ and thought it would be good practice to write a program which solved a given liter puzzle (you have 2 containers with capacities of 3 and 5 liters,
You're passing the Containers as copies. This means that the containers you alter in the pour function are destructed upon function exit.
The solution is to use references:
void pour(Container& a, Container& b)
The & after the type denotes a reference. This means that, instead of copies of a and b being used inside pour, the function gets access to the same a and b as the caller.