第41141题 单选题
判断一个数是否为自守数。自守数的定义是如果一个数的平方其尾数与该数相同,则为自守数,如25的平方是625,其尾数是25,所以25是自守数。相关说法错误的是( )。
N = int(input("输入一个正整数:"))
N1, M1 = N, N * N

Flag = True
while N1 > 0:
    if N1 % 10 != M1 % 10:
        Flag = False
        break
    else:
        N1, M1 = N1 // 10, M1 // 10
if Flag == True:
    print(f"{N}的平方是{N * N},是自守数")
else:
    print(f"{N}的平方是{N * N},不是自守数")
{{ option.label }}
子题{{ index + 1 }} {{ child.type_label }}
{{ option.label }}
✓ 正确 ◐ 部分正确 ✗ 错误
程序运行统计
暂无判题统计
知识点:
提交{{ questionInfo.stats ? questionInfo.stats.submit_count : 0 }}次 正确率{{ statsAccuracy }}%
答案解析