要怎样求结合之后字符串的长度?

键盘输入两个字符,将两个字符串连接(用strcat连接),求连接后字符串的长度?

你题目的解答代码如下:(如有帮助,望采纳!谢谢! 点击我这个回答右上方的【采纳】按钮)

#include <stdio.h>
#include <string.h>

int main ()
{
   char a[100], b[50];
   gets(a);
   gets(b);
   strcat(a, b);
   printf("字符串长度:%d", strlen(a));

   return(0);
}

img

用strlen函数