Java程序猿学习C++之字符串 #include <iostream> #include <string.h> using namespace std; int my_len(const char *str) { int len = 0; // while (*str != '