]>
iEval git - clump.git/blob - intermediare.pl
91df8ae723dc4f842e6c4a8ca534fee5f97f535e
26 my ($dx, $dy) = @
{$diffs[$diff]};
29 my $ni = ($i + 4 + $dx) % 4;
30 my $nj = ($j + 4 + $dy) % 4;
31 $result[$i][$j] = $initial[$ni][$nj];
34 # say 'For diff ', $diff, ': ';
35 # say join ' ', @$_ for @result;
44 for my $x (qw
/0 2 4 6/) {
45 @sum1 = sum_for_diff
$x;
46 @sum2 = sum_for_diff
($x+1);
48 my ($sum1, $sum2, $sumA, $sumB) = (0, 0, 0, 0);
52 my $sum = $sum1[$i][$j] + $sum2[$i][$j];
53 $sum1 += $sum1[$i][$j] << $cnt;
54 $sum2 += $sum2[$i][$j] << $cnt;
55 $sumA += ($sum&1) << $cnt;
56 $sumB += ($sum&2) << ($cnt - 1);
61 printf "%04X + %04X = %016b %016b\n", $sum1, $sum2, $sumA, $sumB;
This page took 0.059433 seconds and 4 git commands to generate.