Hacker News new | past | comments | ask | show | jobs | submit login

Useless use of printf; what's wrong with "puts(str)"?



puts() adds a newline at the end. gcc will happily turn printf("%s\n", str) into puts(str), though.

I've never tested to see if printf("%s", str) becomes the equivalent fputs(str, stdout)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: