ruby implementation of C spell checker from cs50 work