44.编写一个函数,该函数可以统计一个长度为2的字符串在另一个字符串中出现的次数。例如,假定输入的字符串为:asd asasdfg asd as zx67 asd mklo,子字符串为as,则应输出6。
效果
代码
#include <stdio.h>int fun(char *s,char *t){int n=0
时间:2021-06-01 11:19:56
44.编写一个函数,该函数可以统计一个长度为2的字符串在另一个字符串中出现的次数。例如,假定输入的字符串为:asd asasdfg asd as zx67 asd mklo,子字符串为as,则应输出6。
#include <stdio.h>int fun(char *s,char *t){int n=0