发布网友 发布时间:2022-04-25 06:41
共3个回答
热心网友 时间:2023-11-07 23:04
身份证校验码是根据前16位对16个系数乘积之和除以11的余数来确定的,10余数对10个校验码:0,1,2,3,4,5,6,7,8,9,10对应1,0,"X",9,8,7,6,5,4,3,2。计算校验码公式,比如身份证号码在A2,B2输入=LOOKUP(MOD(SUMPRODUCT(--MID(A2,COLUMN(A1:Q1),1),{7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2}),11),{0,1,2,3,4,5,6,7,8,9,10},{1,0,"X",9,8,7,6,5,4,3,2}),要判定对还是错,可以在B2输入=IF(LEN(A2)<16,"不是18位身份证号",IF(--RIGHT(A2)=LOOKUP(MOD(SUMPRODUCT(--MID(A2,COLUMN(A1:Q1),1),{7,9,10,5,8,4,2,1,6,3,7,9,10,5,8,4,2}),11),{0,1,2,3,4,5,6,7,8,9,10},{1,0,"X",9,8,7,6,5,4,3,2}),"对","错"))热心网友 时间:2023-11-07 23:04
假设身份证填在A1热心网友 时间:2023-11-07 23:05
=IF(LEN(A2)<18,"一代",IF(TEXT(CHOOSE(MOD(SUMPRODUCT(MID(A2,ROW($1:$1),1)*{7;9;10;5;8;4;2;1;6;3;7;9;10;5;8;4;2}),11)+1,1,0,"X",9,8,7,6,5,4,3,2),0)=RIGHT(A2),"真","假"))