$p=atan2 1,0; ($a,$b)=<>; if($a>=0){ print 4*$p*((1-$a)**2-(1-$b)**2) }elsif($b<=0){ print 4*$p*((1+$a)**2-(1+$b)**2) }else{ print 4*$p*(1-(1+$a)**2+1-(1-$b)**2) }