赞题库-背景图
单项选择题

下面程序的输出结果是______。
#include <iostream>
using namespace std;
int fun(char *s);
int main()
{
cout<<fun("Hello");
return 0;
}
int fun(char *s)
{
char *t=s;
while(*t!="\0")t++;
return(t-s);
}

A.语法错,不能输出正确结果
B.5
C.6
D.0