Loading collection data...
Collections are a way for you to organize kata so that you can create your own training routines. Every collection you create is public and automatically sharable with other warriors. After you have added a few kata to a collection you and others can train on the kata contained within the collection.
Get started now by creating a new collection.
This comment is hidden because it contains spoiler information about the solution
(Original author here) Oh dear, seems times have moved on since I first dropped in and this kata didn't make the cut. Is there something I could do to modernise it for approval or is it beyond saving?
(Original author here) I'm afraid I am not aware of the etiquette here because I only drop in from time to time. Is there something I should do to this kata to modernise it? Would the "republish" option allow it to get a rating more in line with other kata?
To be honest my main purpose for writing this was to have some fun with the plotting idea referenced in the description, to see if it could spice up an otherwise dry calculation kata. If that's no longer in the spirit of the community here then as a very casual user it's not my place to dispute!
Thanks, I enjoyed this solution. 👍
This comment is hidden because it contains spoiler information about the solution
Thanks @dcsmith for this kata, I found it clearly described and fun to complete.
Thanks for looking at this kata. I'm afraid I missed your feedback message, hence the delay in responding to you.
I'm happy to add them but could you expand a little on why are random tests important here?
Thanks for the feedback. I think that the another extended version of this kata with the other operations is a good idea; that keeps this one nice and short for those in a hurry. I'll write that another kata when I get a moment.
As for the response of
add
ormutliply
being a real number, I think it's better to return aComplex
so that other operations can be chained on it without risking a run time explosion:Thanks for the feedback, I've added the requirement to handle real/complex arguments transparently.
I haven't added any of the additional operations you mention since I was trying to keep this kata nice and short. I'm happy to be argued down on that one if you think it'd be better with some more meat on it.
Sorry it took me so long to address your issue. I completely agree and have changed modulus to a method (and added some more helpful test cases).
Thanks for checking this. I'm confused though. Isn't that what it currently says?
Good spot and thanks for the feedback. I've added a test to cover the iteration order.
Ouch! Thanks for pointing that out. I've corrected that test and reduced the threshold to the correct value of 2 (as per http://en.wikipedia.org/wiki/Mandelbrot_set).
Ah, I understand now. I agree and have removed the final tests for Complex so you are free to delete or reimplement the provided Complex as you like; only the
findEscapes(...)
function is tested now, which better fits the purpose of this kata.I'm glad you enjoyed it, Abbe, and thanks for the great feedback!
I'm conflicted on this one. Part of me thinks implementation of complex number arithmetic should be part of the kata, which would then need the tests to help guide it. Another part of me thought of supplying the complex number implementation as a given rather than in the initial solution, so I could tighten the focus of the kata to just the mandelbrot calculations.
Could you perhaps give a little bit more detail to help me understand the way my tests for Complex got in your way?