認識函數strok()--eg.分解保存讀到的IP配置

strtok()函數詳解! 1..定義 分解字符串爲一組字符串。s爲要分解的字符,delim爲分隔符字符(如果傳入字符串,則傳入的字符串中每個字符均爲分割符)。首次調用時,s指向要分解的字符串,之後再次調用要把s設成NULL。在頭文件#include<string.h>中。 2.原型 char *strtok(char s[], const char *delim); 3.說明 (1)當strto
相關文章
相關標籤/搜索