Define a function
bool isOdd (int num) {return num%2 == 1;}
Store all the inputted numbers into a container, e.g. std::list<int> numbers.
Apply this function to every element of the containter and place them into other containers e.g.
for (int x: numbers) {if (isOdd(x)) oddNumbers.push_back(x); else evenNumbers.push_back(x);}
Now display the elements of oddNumbers and evenNumbers.
You can also place into oddNumbers and remove at the same time, so that numbers becomes the evenNumbers set at the end (so only 2 sets are created in the end).
Another way, using only one set throughout, is to use std::partition:
auto iter = std::partition (numbers.begin(), numbers.end(), IsOdd);
Now cout the elements from numbers.begin() to (but not including) iter to get the odds, and from iter onwards to get the evens. However, the order of the elements may not be preserved because of all the swappings done in std::partition.