C#_.NET Interview Cheat sheet
C#_.NET Interview Cheat sheet
Open in app
Search Write
Get unlimited access to the best of Medium for less than $1/week. Become a member
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 1/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
I have been a software developer for 3 years since graduating, during which
I’ve applied to over 1000+ job applications around my field and noticed
specific questions being asked frequently.
Disclaimer: I have made the answers short and simple as I find this works best
during interviews, please feel free to research in-depth about a topic you are
unfamiliar with.
We’ll start with explaining the four pillars of OOP (Object orientated
programming):
Encapsulation:
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 2/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
Internal: Can be used to access members from the same assembly but
not a different assembly
Abstraction:
Polymorphism:
Overloading: writing two or more methods in the same class by using the
same method name, but the passing parameters are different.
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 3/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
SOLID principles:
Question: What is SOLID?
A class is open for extension and closed for modification. For example,
utilising an inheritance, so it is open for extension but closed for
modification.
You should be able to use any derived class instead of a parent class and have
it behaved in the same manner without modification. The parent class
should be able to refer to child objects seamlessly during runtime
polymorphism.
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 4/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
It ensures that a derived class does not affect the behaviour of the parent
class.
You should not be forced to implement interfaces you do not use. Instead of
one big interface, many small interfaces are preferred based on groups of
methods, each one serving one sub-module.
The CLR is essentially the heart of the .net framework, it helps the
development process by offering services such as: memory management,
debugging and security (to name a few), code which runs on the CLR is
known as managed code.
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 5/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
Garbage Collection:
The garbage collector manages the allocation and release of memory for an
application.
Generics:
Provides type safety by allowing you to tailor classes and functions to precis
data types. For example, Lists and arrays where it is required to specify the
data type to prevent irrelevant values from being placed inside.
Managed code runs on the CLR and provides services such as: Garbage
collection and reference checking among other things. so essentially it is
code that is managed by the CLR.
Boxing vs Un-Boxing:
C# Knowledge Questions:
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 6/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
What is [Blank]?
Object:
Class:
Constructor:
Jagged Array:
Of course there are hundreds of questions that can be asked but these are my
select few that I have come across the most frequent. It is also advised to
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 7/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
prepare for questions outside of the list above to solidify your understanding
of the language/framework.
Let me know if I have missed any questions or if you think you have a better
explanation.
I will be releasing more cheat sheets covering: JavaScript, REST API, JSON,
SQL and also Python and Machine Learning. Thank you for reading.
No responses yet
Respond
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 8/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 9/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
Ashraf Rahman
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 10/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
Lists
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 11/12
2/24/25, 2:00 PM C#/.NET Interview Cheat sheet. I have been a software developer for 3… | by Ashraf Rahman | Medium
https://medium.com/@96ashraf96/c-net-interview-cheat-sheet-3eea66aab805 12/12