C語言進階:第31課:字符串典型問題分析

下面的程序輸出什麼,爲何? 數組 char buf[10] = {0}; char src[] = "hello %s"; snprintf(buf, sizeof(buf), src); printf("buf = %s\n", buf); 編譯運行:函數 ~/will$ gcc test.c test.c: In function ‘main’: test.c:9: warnin
相關文章
相關標籤/搜索