Run ID 作者 问题 语言 测评结果 时间 内存 代码长度 提交时间
37066 lnx 合法C标识符 C++ 通过 0 MS 248 KB 404 2024-01-19 14:56:46

Tests(3/3):


#include<bits/stdc++.h> using namespace std; int main() { char ch[20]; cin>>ch; for(int i=0;i<strlen(ch);i++) { int a=(int)ch[i]; if(i==0) { if(!((a>64&&a<91)||(a>96&&a<123))) { cout<<"no"; return 0; } } else { if(!((a>47&&a<58)||(a>64&&a<91)||a==95||(a>96&&a<123))) { cout<<"no"; return 0; } } } cout<<"yes"; return 0; }


测评信息: