coffeescript ordering determinator script