Another clear code challenge

Zhanyong posted his own programming challenge, including this comment:

“The merit of an entry will be judged mainly by how clear the code is, not necessarily the efficiency”

Right on!

This one is a little bit more challenging that mine, but it should be interesting.