创建程序输出字符的unicode码

来源:互联网 发布:铁路造价软件下载 编辑:程序博客网 时间:2024/05/17 14:26
// Copyright (c) 2014软件技术1班            // All rights reserved.             // 作    者:A24龙俊全         // 完成日期:2014年 11 月 25 日             // 版 本 号:v1.0             //             // 问题描述:创建一个程序来输出字符的值。            // 输入描述:无            // 程序输出:人品计算器 using System;using System.Collections.Generic;using System.Linq;using System.Text;namespace RenPing{    class Program    {        static void Main(string[] args)        {            string a;            int b=0;            Console.Write("人品评估报告\n");            Console.Write("姓名:");            a = Convert.ToString(Console.ReadLine());            for (int i = 0; i <a.Length; i++)            {                b += (int)a[i];            }             b = b / 1000;            Console.Write("分值:{0}\n",b);            if (b == 82) Console.Write("评价:我是主宰2333333");            if (b < 30) Console.Write("评价:万中无一的渣渣");            else if (b < 50) Console.Write("评价:人品不好");            else if (b < 70) Console.Write("评价:人品一般");            else if (b < 90) Console.Write("评价:人品好");            else Console.Write("评价:人品爆表");                        Console.Read();        }    }}

总结:懂得了提取字符的unicode码
0 0
原创粉丝点击