finish Solution 2 + add test8