attempts to find the nth prime in Ruby