Run ID | 作者 | 问题 | 语言 | 测评结果 | 时间 | 内存 | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
243 | 阿** | 合法的标识符 | Python3 | 通过 | 28 MS | 3372 KB | 264 | 2023-11-10 09:54:28 |
s = input() def is_valid_identifier(s): if not s: return "no" if s[0].isdigit(): return "no" for char in s: if not (char.isalnum() or char == '_'): return "no" return "yes" print(is_valid_identifier(s))