changed echo -e to printf to be more portable