• 梯数得分循环


    {
        class Program
        {
            static void Main(string[] args)
            {
                while (true)
                {
                    int sum = 0;
                    for (int i = 1; i <= 100; i++)
                    {
                        if (i == 70)
                        {
                            Console.WriteLine("跌倒了");
                        }
                  
                        if (i<= 49)
                        {
                            sum = sum + i;
                            Console.WriteLine("您"+i+"层的得分为"+sum);
                          
                        }
                        else if (i > 49 && a <= 100)
                        {
                            sum = sum + 10;
                            Console.WriteLine(("您"+i+"层的得分为"+sum));
                        }
                        else
                        {
                            Console.WriteLine("出错");
                        }
                        Thread.Sleep(1000);//延时一秒
                    }
                  
     
                    Console.ReadLine();

  • 相关阅读:
    二分查找
    二分排序
    How to use hdu?
    HGOI 20200721
    HGOI 20200720
    HGOI 20190719
    HGOI 20200716
    HGOI 20190714
    LCA 的一些扩展算法
    HGOI 20190711
  • 原文地址:https://www.cnblogs.com/lk-kk/p/4381758.html
Copyright © 2020-2023  润新知