refactor and create functions

refactor addQuestion function and create addEditAnswer and
removeEditAnswer function