fix puts problem