Convert value to degree : atan2 « System Functions « Perl






Convert value to degree

      

$y = 1.15470053837925;
$x = 2.0;

$conversion = 180 / 3.14159265358979;

print "The angle = ", $conversion * atan2($y, $x), " degrees.";

   
    
    
    
    
    
  








Related examples in the same category

1.print (4 * atan2 1, 1);