181 reputation
3
bio website
location
age
visits member for 4 years, 3 months
seen Jan 20 '13 at 20:34

Jul
25
comment Are `break` and `continue` bad programming practices?
@Evan I do see your point though - ie 'what if you need to break out of a foreach loop?' - Well, there should only be one break maximum in my opinion from the loop.
Jul
25
comment Are `break` and `continue` bad programming practices?
@Evan The condition is not applicable to a foreach loop as this will just iterate every item in a collection. A for loop is similar in that it should not have a conditional end point. If you do need a conditional end point then you need to use a while loop.
Mar
16
awarded  Commentator
Mar
16
comment Are `break` and `continue` bad programming practices?
+1 But actually your < comparisons need to be <= to match the OPs solution
Mar
16
answered Are `break` and `continue` bad programming practices?
Feb
18
awarded  Teacher
Feb
18
comment When should I use—and not use—design patterns?
@S.Lott I think don't think the OP is talking about "good, but informal ideas". I think they are talking about really quite rigid class structures as set out in many design-pattern books.
Feb
18
comment When should I use—and not use—design patterns?
Whenever you write some code with objects interacting you are using a design pattern. It may not be a published pattern or even a very good pattern - but it is a pattern. I think the 'pattern sceptics' who "actually use them all the time" will not be using out-of-the-box GOF patterns in their entirety and I think this is the danger that the OP seems to be heading towards in their seeming determination to apply design patterns whenever possible even if it's overkill.
Feb
18
comment When should I use—and not use—design patterns?
@S.Lott I don't think you can say they were verbal shorthand at first, because then you raise the question of verbal shorthand for what? You can't have the descriptor with nothing to describe. Fair enough, their primary use might be as a verbal shorthand. But if their primary use is a verbal shorthand then that doesn't make them much good for actually solving problems :)
Feb
18
comment When should I use—and not use—design patterns?
@7vies I don't think design patterns were introduced to be verbal shorthand. I think they have become verbal shorthand for those familiar with them.
Feb
18
comment When should I use—and not use—design patterns?
Good point for the benefits of using them as verbal shorthand for complex concepts. It's making sure you're using the correct complex concept in the first place that is key :)
Feb
18
comment When should I use—and not use—design patterns?
+1 It's the job that must be identified and understood before the tool can be chosen - Zen :)
Feb
18
answered When should I use—and not use—design patterns?
Jan
14
awarded  Supporter