public static void Main() { //create context action context = new context(); int a = 2; int b = 5; action = new ConcreteStrategyAdd(a, b); context.setStrategy(action); // if(action == new ConcreteStrategyAdd) // { // context.setStrategy(action); // System.Console.WriteLine("hello from instance"); // } // return 0; }