Basic algorithms in javascript, as a learning project.