<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <title></title> <script type="text/javascript"> var r=prompt('请输入半径'); var h=prompt('请输入高度'); r=Number(r); h=Number(h); var v;
//PI=π v=Math.PI*r*r*h; v=Number(v); alert(v); </script> </head> <body> </body> </html>