C# Interview Questions

C# Interview Questions

  1. What is interface in c#?
  2. What is an abstract class?
  3. What are constructor in C#?
  4. Does C# support C type macros?
  5. What is mean “Death of Diamod”?
  6. Can you inherit multiple interfaces?
  7. What is the name of c#.net compiler?
  8. Does C# support multiple inheritance?
  9. Why would you use untrusted verificaion?
  10. C# constructors cannot be inherited. Why?
  11. Is it possible to have a static indexer in C#?
  12. How can I access the registry from C# code?
  13. Difference between value and reference type?
  14. How do I get deterministic finalization in C#?
  15. Why multiple Inheritance is not possible in C#?
  16. What is Form Closed and Form Closing events?
  17. An assembly can be stored across multiple files?
  18. Which one is trusted and which one is untrusted?
  19. What is true about read only variable in C# code?
  20. Is it possible to inline assembly or IL in C# code?
  21. How can I get the ASCII code for a character in C#?
  22. What is the difference between direct cast and ctype?
  23. How’s method overriding different from overloading?
  24. What is difference between deep copy & sallow copy?
  25. What connections does Microsoft SQL Server support?
  26. What does dispose method do with the connection object?
  27. What is the difference between const and static read-only?
  28. What does the keyword virtual mean in the method definition?
  29. C# collection allows accessing an element using a unique key?
  30. What is the difference between the Debug class and Trace class?
  31. What is the main difference between delegate and an event in c#?
  32. Can you change the value of a variable while debugging a C# application?
  33. How do you choose 1 entry point when C# project has more Main ( ) method?
  34. How we hand Sql exceptions? What is the class that handles SqlServer exceptions?
  35. Why cannot you specify the accessibility modifier for methods inside the interface?
  36. Which debugging window allows you to see the methods called in the order they were called?
  37. Which debugging window allows you to see all the name and values of all the variables in scope?
  38. Is there a way of specifying which block or loop to break out of when working with nested loops?
  39. Is it mandatory to implement all the methods which are there in abstract class if we inherit that abstract class..?
  40. Why we using in header file using system and more header file is in C# what is difference between and all header file?