Started working on a ruby version

This also includes tests