Awesome! I'm glad that you found it helpful! In practice I find I almost never use them to be honest. It was a lot more common when I did embedded coding but very rare in C#.
Great question! My generic answer is: it depends! 😁 I think the goal is readability here. I'd argue maintainability and flexibility *shouldn't* be as important with Enums because ideally you're not touching them again 😉 so readability takes priority here for me. With that said, if you and your team are more comfortable working with decimal (and you understand behind the scenes it's using bits for the flags) then I see no issue. I opt for binary just so that I'm thinking in bits and have my head on straight 🙂
Great video. I've never come across a need to use flags. I am curious about others use cases for using flags though.
Awesome! I'm glad that you found it helpful!
In practice I find I almost never use them to be honest. It was a lot more common when I did embedded coding but very rare in C#.
Great explanation. Is it bad practice to use decimal values for flags from the beginning?
Great question! My generic answer is: it depends! 😁
I think the goal is readability here. I'd argue maintainability and flexibility *shouldn't* be as important with Enums because ideally you're not touching them again 😉 so readability takes priority here for me.
With that said, if you and your team are more comfortable working with decimal (and you understand behind the scenes it's using bits for the flags) then I see no issue.
I opt for binary just so that I'm thinking in bits and have my head on straight 🙂
@@DevLeader Thank you
👏👍
Thanks! I hope that you found this helpful 🙂
What did I just watch..? 🙆♂
Hey there! Is there anything I can clarify from the video? I'm sorry if it didn't come through clearly!