tag:blogger.com,1999:blog-7178498599053473447.post8235985221005628416..comments2023-03-24T19:02:25.399+05:30Comments on InterviewCity.com: Can a Class can be Derived from Abstract Class in C#Unknownnoreply@blogger.comBlogger1125tag:blogger.com,1999:blog-7178498599053473447.post-4499878940268381172012-01-31T20:13:31.156+05:302012-01-31T20:13:31.156+05:30Some questions I got in my technical discussion ro...Some questions I got in my technical discussion round.<br /><br /><br />public classA <br />{<br /> fun (){"A";}<br />}<br />public classB :ClassA<br />{<br /> fun (){"B";}<br />}<br /><br />A a = new B();<br />a.fun();<br /><br />Out put "A";<br />----------------<br /><br />public classA <br />{<br /> virtual fun (){"A";}<br />}<br />public classB :ClassA<br />{<br /> override fun (){"B";}<br />}<br /><br />A a = new B();<br />a.fun<br /><br />Out put "B";<br />----------------<br />============================<br />Sealed Method<br />=============================<br />Method Name Implicit Typing<br />=============================<br />What is purpose of System.Object?<br />This allows C# built-in types to be worked with in a manner similar to reference types. From an object-oriented <br /><br />perspective, under Type System Unification both reference types and value types are objects.<br /><br /><br />==================================<br />Dependency Property Vs Normal Property<br /> <br />Either can be used , except in case of animatable properties<br />As far as I know, DependencyProperty is only required when you need <br />1.PropertyValue inheritence<br />2.you need to allow the property to be set in Style setters <br />3.Use animation for the property <br /><br />============================================<br /><br />Commanding Vs Eventing<br /><br />Commands provide two main benefits over event handlers:<br /> 1.commands are not linked to the caller, <br />so same command is not dependent and can be called from menu item, toolbar button, keyboard, etc. <br />2.commands provide support for enabling/disablingAnonymousnoreply@blogger.com