efrei/scripting/perl/circonference.pl
2022-07-08 08:40:55 +02:00

12 lines
256 B
Perl
Executable file
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#!/usr/bin/env perl
use strict;
use warnings;
use Math::Trig;
# Programme qui calcule la circonférence dun cercle de rayon de 12.5.
my $radius = 12.5;
my $circ = 2 * pi * $radius;
print "La circonférence d'un cercle de rayon $radius est $circ\n";