Result

AC

Duration

511ms

Code [DL]

x,y,z,*s=map(int,open(0).read().split())
print(sum((s[i]-x)*((s[i-5]-y)*(s[i-1]-z)-(s[i-2]-y)*(s[i-4]-z))for i in[0,3,6])//6)

stdin

87 04 82
46 78 36
58 19 80
88 78 90

stdout

17573

stderr

strace