编号 题目 状态 分数 总时间 内存 代码 / 答案文件 提交者 提交时间
#2421 #1001. 中心字母 Compile Error 0 0 ms 0 K C++ 17 (Clang) / 176 B t330026054 2023-11-17 15:25:09
显示原始代码
#include <iostream>
using namespace std;

int main() {
    char str[101];
    int recorder = 0;
    cin.getline(str, 101);
    recorder = strlen(str);
    cout << str[recorder / 2];
}

编译信息

/sandbox/1/a.cpp:9:11: error: use of undeclared identifier 'strlen'
        recorder=strlen(str);
                 ^
1 error generated.