Interpreter Design Pattern

preview_player
Показать описание
Interpreter is a behavioral design pattern to modify the output by context, for the same input. There could be multiple motivation to implement this pattern, for e.g. the given data may have to be represented in different formats based on from where it is getting executed, in other words, any changes to the environment will affect the outcome. So the user will see different results based on from where he/she is executing the code. It is like the format of date changes by country. e.g. in India the standard format is dd/mm/yyyy and in USA it is mm/dd/yyyy though the date is the same everywhere. But a given website will show the date in various formats depending on from where the site is being opened.

I hope you enjoyed this video, please like share and subscribe and remember to press the bell icon. Thanks for watching.

Рекомендации по теме