Translate ruby source code complete explaination.