#include<cstdio>
#include<algorithm>
using namespace std;
struct dreptunghi
{
int x1,x2,y1,y2;
dreptunghi(int xs=0,int ys=0,int xd=0,int yd=0)
{
x1=xs;
x2=xd;
y1=ys;
y2=yd;
}
};
dreptunghi a,b,c,anb,anc,bnc,anbnc;
dreptunghi d(dreptunghi a,dreptunghi b)
{
dreptunghi ans;
ans.x1=max(a.x1,b.x1);
ans.x2=min(a.x2,b.x2);
ans.y1=max(a.y1,b.y1);
ans.y2=min(a.y2,b.y2);
if(a.x1>b.x2||a.x2<b.x1||a.y1>b.y2||a.y2<b.y1)
{
return dreptunghi(0,0,0,0);
}
return ans;
}
long long perimetru(dreptunghi a)
{
return(1LL*2*(a.x2-a.x1)+1LL*2*(a.y2-a.y1));
}
long long arie(dreptunghi a)
{
return(1LL*(a.x2-a.x1)*(a.y2-a.y1));
}
int main()
{
freopen("reuniune.in","r",stdin);
freopen("reuniune.out","w",stdout);
scanf("%d%d%d%d%d%d%d%d%d%d%d%d",&a.x1,&a.y1,&a.x2,&a.y2,&b.x1,&b.y1,&b.x2,&b.y2,&c.x1,&c.y1,&c.x2,&c.y2);
anb=d(a,b);
anc=d(a,c);
bnc=d(b,c);
anbnc=d(anb,c);
long long ans;
ans=arie(a)+arie(b)+arie(c)-arie(anb)-arie(anc)-arie(bnc)+arie(anbnc);
printf("%lld ",ans);
ans=perimetru(a)+perimetru(b)+perimetru(c)-perimetru(anc)-perimetru(anb)-perimetru(bnc)+perimetru(anbnc);
printf("%lld\n",ans);
}