fork download
  1. #! usr/bin/perl
  2.  
  3. print "What is the radius of the circle?/n";
  4.  
  5. my $radius = <>;
  6.  
  7. my $area = 3.14 * ($radius ** 2);
  8.  
  9. my $circumference = (2 * $radius * 3.14);
  10.  
  11. my $diameter = (2 * $radius);
  12.  
  13. print "Diameter: $diameter/n
  14. Circumference: $circumference/n
  15. Area: $area/n";
Compilation error #stdin compilation error #stdout 0s 0KB
stdin
5
compilation info
===SORRY!===
Unsupported use of <>; in Perl 6 please use lines() or () at line 5, near "<>;\n\nmy $a"
stdout
Standard output is empty