The Cody Interview: Alfonso Nieto Castañón
If you play Cody, you probably already know the name Alfonso Nieto Castañón. He is the number one player by rank, and his answers tend to sprout comments like “Amazing!” and “How did you think of that?!”
Alfonso is the guy you want to have in your community. Brilliant, generous, and energetic, he moves through Cody like an artist, insightful answers flying from his fingertips. Through his Cody interactions alone, I suspect he has taught us more MATLAB than many a professor.
He was kind enough to let us do a virtual interview with him. Spoiler alert! In one of his answers he says he solves easy Cody problems while he’s on the phone. I like that. I’m lucky if I can draw a stick man while I’m talking on the phone.
A: I am a computational neuroscience researcher, and my main focus is on neuroimaging methods. I use Matlab constantly in my research for all sorts of projects. It may be simply using well-established neuroimaging tools (e.g. SPM), developing my own (e.g. Conn), building neural models in Simulink, performing statistical analyses, or even developing real-time speech synthesizers, Matlab is always my first choice. I learned Matlab during my undergraduate studies as a telecommunication engineer, and was quickly won over by the incredible pace at which I could develop a project in Matlab compared to C or other less specialized languages. By the time I was in my graduate studies I was using Matlab almost daily, and I do not believe I have stopped since.
A: I was just browsing Matlab Central when I first saw a banner for Cody, and I was quickly hooked by the simple mini-problems, doing “just one more” over and over again. But it was really the wonderful community of users that started growing around Cody what kept me coming back, learning from and being often surprised by other people solutions, and enjoying the continuous stream of imaginative problems that have since then been posted.
A: Both Cody and the Matlab Contest were fantastic ways of learning from the solutions and the thought-process of others. The old/classic Matlab contest had this fantastic pacing, and a great sense of community (and the rush of last minute solutions!). Cody’s permanence, on the other hand, may miss the rush of a more bounded competition, but it brings in return a never-ending source of enjoyment and learning opportunities. I often find myself revisiting old problems or solutions just to see what other people may have come up with in the meantime, or following specific players just because I enjoy their way of solving problems or because I enjoy the sort of problems that they create. Also the possibility to create your own problems adds a whole different perspective to Cody, and I may have found myself spending way too much time learning the inner workings of Cody just to see “what could be done” with it.
A: Not terribly much. It is true that at times I may have gone and solved some perhaps not-terribly-interesting problems just for the thrill of catching that first position, but mostly I come back to Cody looking forward to being surprised by some new problems or solutions, or just staying in touch with the great community here.
A: My time on Cody fluctuates a lot, depending on my work or life schedule, but if I am caught up in a series of interesting problems I do have to make a real effort not to let Cody take over too much time from either.
A: It depends a lot on the problem. There are some interesting problems where I would send one solution after another until I cannot find other ways to “improve” it. Also, when other players are actively sending solutions to the same problems I may get caught in this fun collaboration where we would be trying to build on each other’s ideas. It also depends on the setting, if I am on my phone I may go for simpler or shorter problems, or if I am just relaxing having a coffee perhaps I may take the time to think about some really complex or interesting problem that I read on Cody some time back and never had the time to solve. Last, sometimes I may just feel like revisiting old problems or solutions to see if I can think of a better solution or just wondering what others may have come up with since I last visited them.
A: For me typically a good Cody problem would have a strong testsuite (avoiding simple look-up table solutions), would not have an immediately obvious “best” way of solving it, and it would not over-engineer the range of expected solutions (e.g. allow some tolerance in error checking, do not forbid or discourage the use of alternative solutions, etc.) Of course I have seen many fantastic problems that break about every of these rules, so new problem creators should probably just follow their instinct and know that their problems will get better with practice. A good place to start is probably to try to find inspiration in the way other people create their problems, I would recommend Richard Zapor, Ned Gulley, Bryant Tran (bmtran), or Tim Vaughan (the cyclist) as some of my favorite problem creators out there. Also I would recommend playing with the format to see what works best. Lately I am increasingly enjoying creating problems that attempt to somewhat explore the limits of what can be done in Cody (e.g. freepasses, Blockland) and, while this might not bring as much fun to others, I am certainly enjoying it! So again, just follow your instincts and experiment a bit.
A: The answers I enjoy the most typically would surprise me by using an unexpected approach, some Matlab functionality I never heard of or considered in the context of this problem, or just by virtue of their goofiness or ingenuity.
A: This would be a very long list. I would say that some of the players who manage to very consistently create solutions that I am sure to enjoy or learn something from are Bryant Tran, with whom I shared the thrill of “discovering” Cody, learning to write highly optimized solutions, and unearthing quite a few hacking tricks, and Tim, who not only creates beautifully efficient code but also he is the one player I can always count on to be able to solve pretty much any problem I throw at him.
Among the problem creators that I enjoy the most I would “special mention” the prolific Richard Zapor (with a ton of fantastic problems in his GJam competition series; his PACMAT series was also ridiculously fun), and Ned Gulley (his problems consistently hit the perfect balance between simplicity of definition, and complexity of possible solutions/approaches; e.g. Remove the air bubbles, Return its own character count, Stride of the longest skip sequence, are really beautiful problems that I often come back to). I also had great fun with Khaled Hamed’s functional programming problems (problems 1198, 1210, 1224), as well as the many hacking problems out there –– starting with Óscar’s “Now!” series (problems 901, 907), Frequency Domain’s “Get me!” series (problems 1745, 1746, 1747, 1752) and my own “Singularity 2.0” series (problems 1769, 1770, 1764).
A: Those sorts of interactions make some of the most memorable moments for me in Cody (and they are always more like conversations or shared experiences, only perhaps disguised as battles). In fact they are probably what have made many of the problems and solutions that I mentioned above particularly meaningful or enjoyable to me. As an example when the “Get me!” series of hacking problems was created it brought together many players trying to find better ways to build strong testsuites that would protect against hacking attempts (and/or find better hacks to break stronger testsuites), and we built from each other’s ideas in what ended up being a remarkable collective experience of discovery. And even though it was somewhat sad to me in the end that we found some sort of all-purpose hack that could not be currently protected against, which unavoidably ended our quest, the entire process was a genuinely fun/bonding/instructive experience.
A: There are a few of these “tricks”. Using command syntax (e.g. print file) instead of function syntax (e.g. print(‘file’)), using str2num to define a “constant” vector or matrix, and the somewhat ugly but necessary ans trick, would probably fall into the “recommendable” category, and they will help you shave a few points of almost any solution. The infamous regexp trick (as well as all sorts of hacking tricks) would probably fall into the “not recommendable” category, as these inevitably flatten the score function (they give any solution, independently of how clever or absurd it is, the exact same score). Despite these tricks, my favorite pleasures really come from finding new simpler ways to approach a problem, or applying some linear algebra tricks, or these sort of discoveries which lead to some small improvements in score in a way that was somewhat unexpected or surprising.
A: This would again be a very long list. Most importantly I have widened considerably the range of approaches that I consider now for almost any “real world” problem, but in practical terms I have also learned a lot about regexp functionality, Java usage in Matlab, tricks to speed-up your code, and a lot of new Matlab functionality that I was not aware of (e.g. uint64 operations, timeseries objects, map containers, etc.), just to mention a few examples.
A: I believe mostly I would like to better be able to search/browse through old problems and solutions. For example, being able to search problems/solutions that I (or specifically somebody else) ‘liked’ would make the task of coming back to revisit some of the most memorable solutions/problems or discovering new solutions that you may have missed much simpler (in this regard something like a “self-like” marking would be useful, as I would love to hear/follow which of their own problems/solutions some players are most “proud” of).
A: I love the Blogs section (Cleve’s and Loren’s are some of my favorites), very sporadically contribute to the Newsgroup or Answers sections, and have been lately doing my first steps on Trendy (and of course was a big fan of the Matlab Contest).
A: accumarray, bsxfun, and cellfun/arrayfun/structfun are incredibly flexible and useful functions that are somewhat underused in my opinion.
A: svd (I would spend my day doing linear algebra tricks)
A: To close I would just like to reiterate how much I appreciate the excellent work of the Mathworks team which makes all of these shared learning and fun experiences possible, as well as to thank the amazing Cody community for sharing so much of their time, brainpower, and humor with the rest of us.
コメント
コメントを残すには、ここ をクリックして MathWorks アカウントにサインインするか新しい MathWorks アカウントを作成します。