Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
Event test
//Rextester.Program.Main is the entry point for your code. Don't change it. //Compiler version 4.0.30319.17929 for Microsoft (R) .NET Framework 4.5 using System; using System.Collections.Generic; using System.Linq; using System.Text.RegularExpressions; class Base { public static void Boo() {Console.WriteLine("Boo!");} public static void Do() {Console.WriteLine("DoBase!");} } class Derived : Base { public static void Do() {Console.WriteLine("DoDerived!");} public static event Action<int> SomethingChanged; private static HashSet<Action<int>> includeInSomethingChanged = new HashSet<Action<int>>(); public static void IncludeInSuperSomethingChanged(Action<int> callback) { includeInSomethingChanged.Add(callback); } public static void OnSomethingChanged(bool isSuperSomethingChanged) { foreach (Action<int> callback in SomethingChanged.GetInvocationList()) { if (!isSuperSomethingChanged || includeInSomethingChanged.Contains(callback)) { callback(2); } } } } namespace Rextester { public class Program { public static void Main(string[] args) { new Program().Run(); } public void Run() { //Your code goes here Console.WriteLine("Hello, world!"); Derived.Boo(); Derived.Do(); Derived.SomethingChanged += OnSomethingChanged; Derived.SomethingChanged += OnSuperSomethingChanged; Derived.IncludeInSuperSomethingChanged(OnSuperSomethingChanged); Derived.OnSomethingChanged(false); Derived.OnSomethingChanged(true); } void OnSomethingChanged(int i) { Console.WriteLine(i); } void OnSuperSomethingChanged(int i) { Console.WriteLine("Super!" + i); } } }
run
|
edit
|
history
|
help
0
EMV_RESULTAT
Intuit // C# // listing_4.8 (while)
c# değişik bir çizim
assignment no.3.cs
Fórum ➡ My Category Attribute ↔ New Default Attribute: Behavior ♦
double to hex to double lose precision
4647
Game v 1.0
SafeSquareRoot.java
ElaineBrown**