// 6 ways to print Hello, stdio! #include int main(void) { char bytes[] = "Hello, stdio!\n"; // 15 bytes // The easy way %s relies on bytes being 0-terminated printf("%s", bytes); // relies on bytes being 0-terminated for (int i = 0; bytes[i] != '\0'; i++) { fputc(bytes[i], stdout); } // relies on bytes being 0-terminated fputs(bytes, stdout); // write 14 1 byte items fwrite(bytes, 1, (sizeof bytes) - 1, stdout); // %s relies on bytes being 0-terminated fprintf(stdout, "%s", bytes); return 0; }