提交时间:2021-06-27 11:23:52

运行 ID: 21291

#include<bits/stdc++.h> using namespace std; string a; int main(){ cin>>a; for(int i=0;i<a.size();i++){ if(a[i]<='9'&&a[i]>='0'&&i==0){ cout<<"no"; return 0; } if(!(a[i]=='_'||(a[i]>='a'&&a[i]<='z')||(a[i]>='A'&&a[i]<='Z')||(a[i]>='0'&&a[i]<='9'))){ cout<<"no"; return 0; } } cout<<"yes"; return 0; }