Create p074.rb

But it's slow... (about 300 sec.)

TODO: use cache.