A collegue just told me about a DSP challenge on you tube. Level one its just too lame, so here is the link to the second level: https://www.youtube.com/watch?v=0lbgepTiIaU
You opened the pandora box! This destroyed my hope on a cody anti-hacking framework... :'( This solutions means two things: 1 - Mathworks guys will have a hard-time shielding cody (if they dare to); 2 - Matlab is such a beautiful highly-customizable piece of software!
I dont understand what you wanted to do with your test no.4. why dont you just check our answer against the actual factorial, instead of hard coding (truncated) numbers?