Add solution to problem number 9.

Signed-off-by: darkestkhan <darkestkhan@gmail.com>