Hey Alain,

Thanks for reading my story and responding!

You’re very right. The state pattern is by no measure always a good replacement for if-else statements.
However, I’d to challenge the status quo and all if-else fanboiz out here (apparently there’re more than I expected).

Software Developer Manager | Big4 ex. FinTech | Writer with +1M views. Sharing my opinion & what I learn. YT channel youtube.com/c/NicklasMillard

Love podcasts or audiobooks? Learn on the go with our new app.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store