The health industry, where researchers find and publish bad dietary habits, and good doctors use that information to teach patients to change the root causes of poor health, not just the symptoms.
保健行业,研究者在这里查找和发布不良的饮食习惯,然后好的医生会使用这些信息来指导病人如何改变引起疾病的根源,而不仅仅是症状。
So use your discipline to "force your hand" initially into breaking the bad habit with a good one.
所以用你的原则“迫使你的手”最先从坏习惯开始打破,然后取代为好习惯。
Use the power of a fair and open competition to distinguish good options from bad ones.
通过公平公开的竞争选出最好的抉择。
That goes back to that idea of sort of discipline coding. It's easy to have assumptions about what you think are going to come into the program when you writ it. If you really know what they are use them as search, but if you think there's going to be some flexibility, you want to prevent the user getting trapped in a bad spot, and exceptions as a consequence are a good thing to use.
这又回到了规范编码的想法上来了,在你写代码的时候考虑,什么会进入你的代码的思考是简单的,如果你真的知道,他们是用他们来做搜索的,而你希望有一定的灵活性,你想要阻止用户,陷入一个艰难的境地,那么异常是非常实用的。
应用推荐