Result

AC

Duration

523ms

Code [DL]

@z=glob`dd`;$A+=int($_/6)*(@z[$_]-=@z[$_+3])*(@z[$s=++$_%3+3]*@z[$t=($s+1)%3]-@z[$s-3]*@z[$t+3])for(0..8);print$A/6

stdin

97 79 38
53 55 74
04 01 85
76 40 90

stdout

12840

stderr

0+1 records in
0+1 records out

strace