ruby string class does not have append method, changed to concat instead