still working;minor changes