Archived
1
0
This commit is contained in:
2025-10-24 17:20:56 +08:00
parent acc0c9e220
commit e0fbc20716
21 changed files with 0 additions and 0 deletions

19
cs1/C Sharp 1/Program.cs Normal file
View File

@@ -0,0 +1,19 @@
using System;
using static System.Math;
namespace C_Sharp_1
{
public class Program
{
static void Main(string[] args)
{
double r, c, s, v;
Console.WriteLine("请输入半径:");
r = double.Parse(Console.ReadLine());
c = 2 * PI * r;
s = PI * Pow(r, 2);
v = (4 / 3.0) * PI * Pow(r, 3);
Console.WriteLine("圆周长为{0},面积为{1}",c,s);
Console.WriteLine("球体积为{0}", v);
}
}
}