First of all, the program can be reduced in size:
$/=\1;while(<>){$c=($c<<1)+($c>>31)+($.>>2==3?0:ord)}printf"%x",$c
The program calculates a checksum, it does so by iterating over each character of the file (
$/ = \1; while (<>)). It keeps a running, 32 bit checksum, initially zero. For each character, it will rotate the current checksum one bit leftward (note that it's rotating, not shifting). This is the
($c << 1) + ($c >> 31) part. Then for each fourth character, the code point number will be added to the running total. (
$x >> 2 == 3 ? 0: ord); $x ++). Finally, the checksum is printed as a hex number.
Note that it will display different sums depending whether you have a 32-bit or a 64-bit perl!
Abigail