PHP版:
Perl:
# 需要先安装 String::CRC32use String::CRC32;sub getCrc{ open my $fd , '<' , $filepath or die("error"); my $crc2 = crc32($fd); my $crc_out = sprintf("%x", $crc2); print uc($crc_out) ; }
本文共 265 字,大约阅读时间需要 1 分钟。
PHP版:
Perl:
# 需要先安装 String::CRC32use String::CRC32;sub getCrc{ open my $fd , '<' , $filepath or die("error"); my $crc2 = crc32($fd); my $crc_out = sprintf("%x", $crc2); print uc($crc_out) ; }
转载于:https://my.oschina.net/ifeixiang/blog/339506