add solution to class2/ex5