Abstractions

Abstraction is a mechanism in which details of operations are hidden and only relevant details and functionalities needed to solve the current problem are exposed. An example of abstraction is my grandma’s heaven sent brownies recipe, when making the cake I don’t need to know how the flour is processed, how, the milk is processed also, how the sugar is refined and how the cocoa beans used for the chocolate flavour is extracted all I need to know is how to mix the ingredients and bake it. This way I don’t need to worry about the production details on how the ingredients are produced and focus on the problem at hand which is baking the brownie cake. Similarly in programming abstractions work in a similar way they hide the complex details of operations and expose only the functions necessary to solve the current problem. Examples of mechanisms for abstraction in programming is functions, objects, and libraries.