[add] solved problem 5 using a brute-force method