Calculate the area of a circle of given radius : Double : Language Basics PHP Source Code


PHP Source Code » Language Basics » Double »

 

Calculate the area of a circle of given radius




<?php

$radius = 2.0;
$pi = 3.14159;
$area = $pi * $radius * $radius;

echo("radius = ");
echo($radius);
echo("<BR>area = ");
echo($area);
?>

           
       



HTML code for linking to this page:

Follow Navioo On Twitter

PHP Source Code

 Navioo Language Basics
» Double