Welcome to triksbuddy blog. He we discuss on different technology, tips and tricks, programming, project management and leadership. Here we share technology tutorials, reviews, comparison, listing and many more. We also share interview questions along with answers on different topics and technologies. Stay tuned and connected with us and know new technologies and dig down known ones.
Tuesday, November 30, 2021
What is an interface? When to use interface over abstract class?
An interface contains definitions for a group of related functionalities that a class or a struct can implement.
Use interface over abstract class:
a. If the functionality you are creating will be useful across a wide range of disparate objects, use an interface.
b. If you are designing small, concise bits of functionality, use interfaces. If you are designing large functional units, use an abstract class.
Labels:
Interview Question,
OOP
Welcome to triksbuddy blog. He we discuss on different technology, tips and tricks, programming, project management and leadership.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Please keep your comments relevant.
Comments with external links and adult words will be filtered.