fixed some hw problems