add problem 10 C and Ruby solution, Ruby version was too slow.