zoukankan      html  css  js  c++  java
  • 内部类学习

    using System;
    using System.Collections.Generic;

    public class MyClass
    {
    class A
    {
    int a;
    internal protected class B
    {
    public void Display()
    {
    A a1 = new A();
    a1.a = 3;
    Console.WriteLine("a={0}",a1.a);

    }
    }
    }
    public static void RunSnippet()
    {
    A.B b = new A.B();
    b.Display();

    }

    #region Helper methods

    public static void Main()
    {
    try
    {
    RunSnippet();
    }
    catch (Exception e)
    {
    string error = string.Format("---\nThe following error occurred while executing the snippet:\n{0}\n---", e.ToString());
    Console.WriteLine(error);
    }
    finally
    {
    Console.Write("Press any key to continue...");
    Console.ReadKey();
    }
    }

    private static void WL(object text, params object[] args)
    {
    Console.WriteLine(text.ToString(), args);
    }

    private static void RL()
    {
    Console.ReadLine();
    }

    private static void Break()
    {
    System.Diagnostics.Debugger.Break();
    }

    #endregion
    }

  • 相关阅读:
    搜索部分学习小结
    递归与搜索部分知识点小结
    匿名函数
    监督学习和非监督学习
    单变量线性回归
    神经网络(2)
    html
    javascript
    win10+celery4.x以上+redis的天坑
    Django-Views
  • 原文地址:https://www.cnblogs.com/jinweijie0527/p/4916278.html
Copyright © 2011-2022 走看看