Myblog's Blog

October 26, 2009

C# .NET questions

Filed under: C# — technospider @ 2:40 am

Q1: Can DateTime variables be null?
A1: No, because it is a value type (Struct)

Q2: Describe the accessibility modifier protected internal
A2: Members are accessible to derived classes and classes within the same Assembly

Q3: Difference between an interface and abstract class?
A3: In the interface all methods must be abstract, in the abstract class some methods can be concrete. In the interface no accessibility modifiers are allowed, which is ok in abstract classes.

Q4: What are Design Patterns?
A4: It is a big topic in Object Oriented, so for more information see this, http://dofactory.com/Patterns/Patterns.aspx

Q5: What do you know about .net framework 3.0 ?
A5: any answer that introduces Windows Communication Foundation (WCF), Windows Workflow Foundation (WF), Windows Presentation Foundation (WPF) and Windows Card Space (WCS) is right, also you can mention that it was originally called WinFX

Q6: What do you know about ATLAS (Microsoft ASP.net AJAX Extensions) ?
A6: for more information check here, http://ajax.asp.net

Q7: What do you know about Agile software methodologies?
A7: http://en.wikipedia.org/wiki/Agile_software_development

Q8: What do you know about Web Services Enhancements (WSE)?
A8: http://msdn.microsoft.com/webservices/webservices/building/wse/default.aspx

Q9: What is AJAX ?
A9: Asynchronous Javascript And XML

Q10:What is NUnit, or What is Unit testing?
A10: Unit testing: is a procedure used to validate that a particular module of source code is working properly from each modification to the next. The procedure is to write test cases for all functions and methods so that whenever a change causes a regression, it can be quickly identified and fixed. Ideally, each test case is separate from the others; constructs such as mock objects can assist in separating unit tests. This type of testing is mostly done by the developers, NUnit is a famous tool for Unit Testing in .net

Q11: What is mutable type ? immutable type ?
A11: Immutable type are types whose instance data, fields and properties, does not change after the instance is created. Most value types are immutable, but the mutable type are A type whose instance data, fields and properties, can be changed after the instance is created. Most Reference Types are mutable.

Q12: What is the difference between String & StringBuilder classes?
A12: String is an immutable type while StringBuilder is a mutable type

Q13: What’s the difference between C# 1.0 & C# 2.0?
A13: Any answer that introduces stuff like, Generics, Anonymous Methods, Nullable types, Iterators … etc, is correct

Q14: Without using the multiplication or addition operations, how can you multiply a number x by 8?
A14: Shift x to the left 3 times, x << 3, because every shift left multiplies the number by 2

Theme: Silver is the New Black. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.