i,j,s,a[1<<17];main(k){for(;~scanf("%d",a+i);s-=1/k*3-2/k)for(k=j=1;j