Extract code that is relative to input and output