with(Math)for(t=atan2;[a,b,c,d,e,f,g,h]=readline().split(' ');)print(+(0>sin(p=t(b-f,a-e)-t(d-f,c-e))*sin(p-t(b-h,a-g)+t(d-h,c-g))))