programming-examples/perl/SystemFunction/Convert value to degree.pl
2019-11-15 12:59:38 +01:00

7 lines
143 B
Perl

$y = 1.15470053837925;
$x = 2.0;
$conversion = 180 / 3.14159265358979;
print "The angle = ", $conversion * atan2($y, $x), " degrees.";