![](https://img-blog.csdnimg.cn/20201014180756919.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
C语言
文章平均质量分 67
ganghuige
IT小小鸟
展开
-
取格式化字符串两头的数值
int is_in_period(int num, char *prd);int main(int argc, char *argv[]){ int num = 15; if( is_in_period(num, "11-20") ) printf("yes!\n"); else printf("no!\n"); exit(0);原创 2013-03-26 09:53:39 · 829 阅读 · 0 评论 -
printf hex msg
static void hexdump (FILE *fp, const char *name, const void *ptr, size_t len) { const char *p = (const char *)ptr; size_t of = 0; if (name) fprintf(fp, "%s hexdump (%zd bytes):\n", name,转载 2016-11-29 15:29:01 · 660 阅读 · 0 评论