为了账号安全,请及时绑定邮箱和手机立即绑定

C#开发轻松入门

难度入门
时长 4小时43分
学习人数
综合评分9.40
833人评价 查看评价
9.5 内容实用
9.5 简洁易懂
9.2 逻辑清晰
系统判定问题有点严重,直接打印出矩形也过,运行错误也过???虽然很感谢出的免费教程,但还是无礼的希望能作出优化。

最新回答 / qq_无心尐爷_0
int是整形 和 string是字符串类型 ,它们是两种类型,声明类型的时候同时只能声明一种类型
有c基础的前五章直接走个过场,看第六章吧。。

已采纳回答 / 慕娘937938
X<= Y ,表示的是X小于或等于Y
int avg=0;
int sum = 0;
for(int i=0;i&lt;num.Length;i++)
{
sum+=num[i];
avg = sum / num.Length;

if(num[i]&gt;avg)
{
Console.WriteLine(..);
}
}

最新回答 / 粗实而夜雨
问题不大,内心知道怎么回事就行了
请问你用的什么护肤水,来一打先
for(int i=0;i&lt;8;i++)
{
if(a[i].score&gt;temp)
{
temp=a[i].score;
k=i;
}
}
Console.WriteLine(&quot;分数最高的是&quot;+a[k].name+&quot;,&quot;+&quot;分数是&quot;+a[k].score);
Student [] a=new Student[8];
a[0].name=&quot;吴松&quot;;a[0].score=89;
a[1].name=&quot;钱东宇&quot;;a[1].score=90;
a[2].name=&quot;伏晨&quot;;a[2].score=98;
a[3].name=&quot;周蕊&quot;;a[3].score=60;
a[4].name=&quot;林日鹏&quot;;a[4].score=91;
a[5].name=&quot;何昆&quot;;a[5].score=93;
等。。。。
struct Student
{
public string name;
public int score;
};
using System;
using System.Collections.Generic;
using System.Text;

namespace Test
{
class Program
{
static void Main(string[] args)
{
double d = 2.5;
double x = d +(double) 1;
Console.WriteLine(x);
}
}
}
string[] b = new string[]{&quot;吴松&quot;,&quot;钱东宇&quot;,&quot;伏晨&quot;,&quot;陈陆&quot;,&quot;周蕊&quot;,&quot;林日鹤&quot;,&quot;何昆&quot;,&quot;关欣&quot;};
int[] a = new int[] { 89,90,98,56,60,81,83,85};
int max=a[0];
string mu=b[0];
for(int i=1;i&lt;a.Length;i++)
{
if(max&lt;a[i])
{
max=a[i];
mu=b[i];
}
}
Console.Write(&quot;分数最高的是{0},分数是{1}&quot;,mu,max);
Console.WriteLine(&quot;O.....O&quot;);
Console.WriteLine(&quot;.O...O.&quot;);
Console.WriteLine(&quot;..O.O..&quot;);
Console.WriteLine(&quot;...O...&quot;);
Console.WriteLine(&quot;..O.O..&quot;);
Console.WriteLine(&quot;.O...O.&quot;);
Console.WriteLine(&quot;O.....O&quot;);
哈哈哈哈哈
为什么没有视频啊
楼下的,还能还能更简洁:
bool HasInt=false;
foreach(int code in num)
if(HasInt=(code%7==0)) break;
Console.Write(HasInt?&quot;有7的整倍数&quot;:&quot;没有7的整倍数&quot;);
课程须知
本课程是C#基础课程,热烈欢迎各位小伙伴拍砖吐槽!!
老师告诉你能学到什么?
1、C#的基本概念 2、Visual Studio的使用技巧 3、C#的语法和程序逻辑

微信扫码,参与3人拼团

微信客服

购课补贴
联系客服咨询优惠详情

帮助反馈 APP下载

慕课网APP
您的移动学习伙伴

公众号

扫描二维码
关注慕课网微信公众号

友情提示:

您好,此课程属于迁移课程,您已购买该课程,无需重复购买,感谢您对慕课网的支持!

本次提问将花费2个积分

你的积分不足,无法发表

为什么扣积分?

本次提问将花费2个积分

继续发表请点击 "确定"

为什么扣积分?

举报

0/150
提交
取消