zoukankan      html  css  js  c++  java
  • Show a heart shaped

    Windows Form application version:

    private void Form1_Load(object sender, EventArgs e)
            {
                this.BackColor = Color.Red;
                System.Drawing.Drawing2D.GraphicsPath path = new System.Drawing.Drawing2D.GraphicsPath();
              
                path.AddArc(90, 30, 150, 150, 135, 195);
                path.AddArc(220, 30, 150, 150, 210, 195);
                path.AddLine(112, 159, 230, 290);
                path.AddLine(347, 159, 230, 290);
                path.AddLine(347, 159, 112, 159);
                this.Region = new Region(path);
            }

    Console application version:

    //Set the text colour as RED here            

    Console.ForegroundColor = ConsoleColor.Red;

     Console.WriteLine();            

    for (int i = 0, m = 1; i < 30; i++)                

    for (int l = 0; l < new[] { 5, 6, 7, 6, 8, 10, 3, 10, 4, 13, 1, 13, 1, 87, 1, 27, 4, 23, 7, 20, 11, 16, 16, 11, 20, 7, 24, 3, 27, 1 }[i]; l++, m++)                     System.Console.Write((i % 2 > 0 ? "love"[m % 4] : ' ') + (m % 29 > 0 ? "" : " "));            

    Console.WriteLine();

  • 相关阅读:
    9月9日刷题
    7-4日刷题
    7-3日刷题
    7-2日刷题
    The Key To Accelerating Your Coding Skills
    初识机器学习
    python数据分析与量化交易
    部署远程jupyter
    SQLserver2008一对多,多行数据显示在一行
    kvm虚拟化
  • 原文地址:https://www.cnblogs.com/Lihao2013/p/3765594.html
Copyright © 2011-2022 走看看