programming assignment#2 - try 3