Simplexer codewars python