c#题 在线等

来源:百度知道 编辑:UC知道 时间:2024/06/24 09:50:30
1.设计一个控制台应用程序:输出“Hello,.NET!”
2.设计一个控制台应用程序:实现加法运算。
3.设计一个控制台应用程序:用户输入一个0-100的整数,系统判断输入的是否正确。如果正确,则输出
此整数所属级别(0-59 不及格,60-69 努力吧,70-79 一般,80-89不错,90-100优秀!)。如果用户输
入格式不正确,则弹出错误提示。
4.让系统随机生成一个0-100的整数,然后输出此整数的个、十、百位
各自的值。
面向对象入门:
5.编写一个类Human,包括字段height、age、sex、weight;利用构造函数初始化所有字段的值为0;添加
一个方法OutputInfo,实现的功能是输出所有字段的值。
在main函数里实例化这个类,并调用OutputInfo方法。
6.编写一个类Human,包括字段height、age、sex、weight,其中age和sex的属性
为可读写;构造函数有两个参数,分别用来初始化age和sex的值,利用构造函数初始化其他字段的值为
100;添加一个方法InputInfo,实现的功能是让用户分别输入并修改age和sex的值。添加一个方法
OutputInfo,实现的功能是输出所有字段的值。
我是急用,别告诉我自己写~能帮忙的帮写一下,我也知道简单!~谢谢了

第一题:
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Test
{
class Program
{
static void Main(string[] args)
{
Console.WriteLine("Hello, NET");
}
}
}

第二题:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Test
{
class Program
{
static double Add(double a, double b)
{
return a + b;
}

static void Main(string[] args)
{
Console.WriteLine(Add(1, 1));
}
}
}
第三题:

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Test
{
class Program
{
static void