Added functions, translator now outputs to a file