implemented Matt's requested additional changes to question 6