Hello, Ariel,
A surprising, but highly useful, relationship is that of an ideal gas at STP and the amount of volume it occupies. Any gas at STP occupies 22.4 liters. CO2, Cl2, CH4, etc. all will fit one mole into 22.4 liters at STP. Think of it as a conversion factor:
At STP. a gas has (22.4 liters/mole).
We can convert the 42.97 grams of CO into moles of CO by dividing by it's molar mass: 28.01 grams/mole.
(42.97 grams)/(28.01 grams/mole) = 1.534 moles CO
Multiply this by the above conversion factor:
(1.534 moles CO)*(22.4 liters/mole) = 34.36 liters
Bob