Live data from Hacker News

Ask HN: How do you help junior developers learn finding edge cases?

news.ycombinator.com

11–18 of 18 posts

Re: Ask HN: How do you help junior developers learn finding edge cases?

#11
post #9

Ask “what edge cases are there?” when first describing the task and let them go off and work a while. Later ask “are there any other edge cases?” and let them work a while longer. Repeat as appropriate. Let them find them on their own for a while or two. Let them miss them on their own for a while or two. At the right time ask “have you thought about this potential edge case?” If you want someone to learn to deal wit…

Thank you. I like your idea of support. Let me try summarizing it with bullet points:

* Maintain a healthy ratio between the knowns and the unknowns.

* Allow time and space to explore, experiment, and especially err -- to build up experience.

Re: Ask HN: How do you help junior developers learn finding edge cases?

#12
The Rapid Software Testing course by James Bach is really good for teaching some metacognitive skills of this.

On a higher abstraction layer, iff you can filter for low-bullshit, some social justice stuff can indeed help someone master the main skills needed to spot diverse failure modes in different user stories. For example, this principle is useful: https://thingofthings.wordpress.com/2014/11/15/the-curb-cut-...

Re: Ask HN: How do you help junior developers learn finding edge cases?

#13

The Rapid Software Testing course by James Bach is really good for teaching some metacognitive skills of this. On a higher abstraction layer, iff you can filter for low-bullshit, some social justice stuff can indeed help someone master the main skills needed to spot diverse failure modes in different user stories. For example, this principle is useful: https://thingofthings.wordpress.com/2014/11/15/the-curb-cut-...

Thank you. I will check out that course.

The link you shared is very interesting. It reminds me of "perverse incentive" [1] and "unintended consequence" [2].

[1]: https://en.wikipedia.org/wiki/Perverse_incentive

[2]: https://en.wikipedia.org/wiki/Unintended_consequence

Re: Ask HN: How do you help junior developers learn finding edge cases?

#14
post #3
post #2

List the properties of an object. List the operations performed. Fill in the matrix. Remember it mostly by remembering your own failures. One should know about all versions of null and empty or overflowed, about stuff being too big, about operations being performed out of sync. Maybe, the easiest is to ask yourself: What can go wrong? on every line of the code.

Thank you. Let me try repeating your advice in my own words: * Collect all assumptions (regarding data and actions). * Attack each assumption by throwing known/common/trivial edge cases at it. * Explore each assumption's necessary conditions: what they are ; how they could possibly be false/broken/absent.

Yes, something like that. With the caveat that we have really deep assumptions about the world and something will always surprise you. Be ready to learn from many past mistakes.

Re: Ask HN: How do you help junior developers learn finding edge cases?

#15
post #2

List the properties of an object. List the operations performed. Fill in the matrix. Remember it mostly by remembering your own failures. One should know about all versions of null and empty or overflowed, about stuff being too big, about operations being performed out of sync. Maybe, the easiest is to ask yourself: What can go wrong? on every line of the code.

Can you elaborate on what you mean by property of an object?

Does operations performed mean all the function calls associated with said property(like some struct or class object??)

Re: Ask HN: How do you help junior developers learn finding edge cases?

#16

The Rapid Software Testing course by James Bach is really good for teaching some metacognitive skills of this. On a higher abstraction layer, iff you can filter for low-bullshit, some social justice stuff can indeed help someone master the main skills needed to spot diverse failure modes in different user stories. For example, this principle is useful: https://thingofthings.wordpress.com/2014/11/15/the-curb-cut-...

cool, are you a software tester?

Bach, and Michael Bolton [1], offer some fresh look at software testing BUT they are also controversial and tend to present their ideas in a demeaning argumentative way.

[1] https://www.developsense.com/index.html

Re: Ask HN: How do you help junior developers learn finding edge cases?

#18
post #17

I would recommend they read the Mom Test book, then have them talk to the business side. You can learn a lot more than what was written down by doing this.

Thank you. I agree. Exploration beyond the technical domain will be beneficial, especially with the right listening mindset.
Post reply on HN