车亚斌_bktAG1
2025-04-28
Console.WriteLine("{0}{1}{2}",ch[1,1],ch[1,2],ch[2,0]);我也不会
你滴勋宗
2025-03-29
using System;
using System.Collections.Generic;
using System.Text;
namespace Test
{
class Program
{
static void Main(string[] args)
{
double salary = 6000.00;//基本工资
double prize = 3200.00;//奖金
double tax = 4500.00;//交税
Console.Write("我的工资奖金总额是{0}元",salary+prize);
Console.WriteLine("我的税后收入是{0}元",salary+prize-tax);
}
}
}
慕慕6092618
2025-03-22
慕函数4583526
2024-09-28
给图给我看看
😉
疯子亨特
2024-09-16
for 循环后面的()是中文状态下的,改成英文输入
慕仔5547257
2024-07-19
首先你在定义的时候用了二维数组来存储一维数组了
慕仔5547257
2024-07-18
看作者的这张图片,这几种方式都可以,你这种多了一个"=",应该是 string[] job = new string[4] { "经理","项目主管","技术总监","财务主管"};

慕仔5547257
2024-07-18
安装的C#版本太旧了。建议你安装较新的软件
lucasj
2024-06-20
using System;
using System.Collections.Generic;
using System.Text;
namespace projAboveAvg
{
class Program
{
static void Main(string[] args)
{
int[] score = {90,65,88,70,46,81,100,68};
string[] name={"景珍","林惠洋","成蓉","洪南昌","龙玉民","单江开","田武山","王三明"};
int sum=0,avg;
for(int i=0;i<score.Length;i++)
{
sum+=score[i];
}
avg=sum/score.Length;
Console.WriteLine("平均分是"+avg+",高于平均分的有:");
for(int n=0;n<score.Length;n++)
{
if(avg<score[n])
Console.Write(name[n]+" ");
}
}
}
}
lucasj
2024-06-11
namespace Test{ class Program { static void Main(string[] args) { double money = 60000.00;//存款金额
string x="";
if(money>=100000) x="送一台微波炉"; else if(money>=50000) x="送一套茶具"; else if(money>=10000) x="送一袋大米"; else x="没有礼品";
Console.WriteLine(x);
} }}
慕斯6196466
2024-03-15
using System;
using System.Collections.Generic;
using System.Text;
namespace Test
{
class Program
{
static void Main(string[] args)
{
//请完善代码
for (int i = 0; i < 7; i++) {
for (int j = 0; j < 7; j++)
{
if (j == i || j == 6 - i)
{
Console.Write("O");
}
else
{
Console.Write(".");
}
}
Console.WriteLine("");
}
}
}
}
慕容2593251
2024-03-12
这是一个初级教程,为了让大家熟悉for循环的基本用法。
漂白猪
2024-03-03
不是数字0,是字母o
漂白猪
2024-03-03
write的W没有大写
qq_半城浮华_0
2024-02-01
Console.Write("平均分是{0},高于平均分的有:",avg) Writer后要加Line,进行换行,输出格式才能与标准答案一致!
qq_半城浮华_0
2024-02-01
using System;
using System.Collections.Generic;
using System.Text;
namespace projAboveAvg
{
class Program
{
static void Main(string[] args)
{
string[,]arr={{"景珍","90"},{"林慧洋","65"},{"成蓉","88"},{"洪南昌","70"},{"龙玉民","46"},{"单江开","81"},{"田武山","100"},{"王三明","68"},};
int sum=0;
for(int i=0;i<arr.GetLength(0);i++){
sum+=int.Parse(arr[i,1]);
}
int avg=sum/arr.GetLength(0);
Console.Write("平均分是{0},高于平均分的有:",avg);
for(int i=0;i<arr.GetLength(0);i++){
if(int.Parse(arr[i,1])>avg){
Console.Write(arr[i,0]+" ");
}
}
}
}
}
慕码人7503021
2024-01-27
x++就是x=x+1,此时x==2了。应为2*2>3
qq_慕数据6062997
2023-12-13
给x赋值为0
x++为x+1算出来为1
x+为x+1 前面x已经为1了 所以这里是2
X%就是x除于2的余数就是2除于2的余数是0
打印出来是0
慕斯卡1359283
2023-11-23
string是Unicode字符序列,字符类型
慕慕6366102
2023-10-15
age=age-2是在Console.WriteLine下面,所以是输出后再执行的。
weixin_慕数据8226140
2023-10-03

那个逗号
weixin_慕丝2463677
2023-09-14
笨蛋,这是O
weixin_慕勒7049366
2023-08-29
电脑打开谷歌浏览器,输入网址打开就好了
慕先生3185827
2023-08-19
在C#的字符串中,"{0}"表示一个占位符,用于将变量或表达式的值插入到字符串中的特定位置。
慕少3482789
2023-08-10
has就是有,Nbr是诺贝尔的缩写,hasNbr是自定义的
慕尼黑6021033
2023-07-23
你才是真正的英雄
慕的地5533952
2023-07-04
666
qq_慕工程3053335
2023-06-07
string[] name=new string[8]
{"吴松","钱东宇","伏晨","陈陆","周蕊","林日鹏","何昆","关欣"};
int[] score =new int[8]{99,90,98,56,60,91,93,85};
int max = score[0];
int j = 0;
for(int i=0;i<score.Length;i++)
{
if(score[i]>max)
{
max=score[i];
j=i;
}
}
Console.WriteLine("最高分数的是:{0},分数是:{1}",name[j],max);
qq_慕工程3053335
2023-06-07
using System;
using System.Collections.Generic;
using System.Text;
namespace Test
{
class Program
{
static void Main(string[] args)
{
//请完善代码
for(int i=0;i<7;i++)
{
for(int j=0;j<7;j++)
{
// if(j==i||j==6-i)
// {
// Console.Write("o");
// }
// else
// {
// Console.Write(".");
// }
Console.Write((j==i||j==6-i)?"o":".");
}
Console.Write("\n");
}
}
}
}
weixin_慕仔3007197
2023-05-16
语句`Console.write((double)3)`中的`(double)`表示将整型3强制转换成双精度浮点型,所以实际上3已经被转换成了3.0。但是`Console.write()`默认输出时不会显示小数点及后面的0,因此输出的是3而非3.0。
若要输出3.0,可以使用`Console.WriteLine()`方法并指定输出格式,例如:
```
Console.WriteLine("{0:F1}", (double)3);
```
其中的`{0:F1}`表示格式化输出第一个参数(即强制转换后的3),保留一位小数。输出结果为`3.0`。