finished prob4