explain how the lung works